aboutsummaryrefslogtreecommitdiff
path: root/src/flatfile.cpp
diff options
context:
space:
mode:
authorJim Posen <jim.posen@gmail.com>2019-01-06 11:43:38 -0800
committerJim Posen <jim.posen@gmail.com>2019-02-22 17:38:45 -0800
commitd6d8a78f26f52fdfe43293686135e2fc6919926c (patch)
tree88e7fdae60dcacd7cede677273556a4c69c4544f /src/flatfile.cpp
parente0380933e3745214331d358bda8c5e79299c84d2 (diff)
Move CDiskBlockPos from chain to flatfile.
Diffstat (limited to 'src/flatfile.cpp')
-rw-r--r--src/flatfile.cpp8
1 files changed, 7 insertions, 1 deletions
diff --git a/src/flatfile.cpp b/src/flatfile.cpp
index 1cdead6bf5..b1ea257da1 100644
--- a/src/flatfile.cpp
+++ b/src/flatfile.cpp
@@ -1,4 +1,5 @@
-// Copyright (c) 2019 The Bitcoin Core developers
+// Copyright (c) 2009-2010 Satoshi Nakamoto
+// Copyright (c) 2009-2019 The Bitcoin Core developers
// Distributed under the MIT software license, see the accompanying
// file COPYING or http://www.opensource.org/licenses/mit-license.php.
@@ -19,6 +20,11 @@ FlatFileSeq::FlatFileSeq(fs::path dir, const char* prefix, size_t chunk_size) :
}
}
+std::string CDiskBlockPos::ToString() const
+{
+ return strprintf("CDiskBlockPos(nFile=%i, nPos=%i)", nFile, nPos);
+}
+
fs::path FlatFileSeq::FileName(const CDiskBlockPos& pos) const
{
return m_dir / strprintf("%s%05u.dat", m_prefix, pos.nFile);