Skip to content

Commit 878bf48

Browse files
committed
dbwrapper: Remove CDBWrapper::GetObfuscateKeyHex
It is an unnecessary method as it is used only two times and only internally, and the whole implementation is HexStr(obfuscate_key).
1 parent 74f7b12 commit 878bf48

File tree

2 files changed

+2
-13
lines changed

2 files changed

+2
-13
lines changed

src/dbwrapper.cpp

Lines changed: 2 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -84,10 +84,10 @@ CDBWrapper::CDBWrapper(const boost::filesystem::path& path, size_t nCacheSize, b
8484
Write(OBFUSCATE_KEY_KEY, new_key);
8585
obfuscate_key = new_key;
8686

87-
LogPrintf("Wrote new obfuscate key for %s: %s\n", path.string(), GetObfuscateKeyHex());
87+
LogPrintf("Wrote new obfuscate key for %s: %s\n", path.string(), HexStr(obfuscate_key));
8888
}
8989

90-
LogPrintf("Using obfuscation key for %s: %s\n", path.string(), GetObfuscateKeyHex());
90+
LogPrintf("Using obfuscation key for %s: %s\n", path.string(), HexStr(obfuscate_key));
9191
}
9292

9393
CDBWrapper::~CDBWrapper()
@@ -141,11 +141,6 @@ const std::vector<unsigned char>& CDBWrapper::GetObfuscateKey() const
141141
return obfuscate_key;
142142
}
143143

144-
std::string CDBWrapper::GetObfuscateKeyHex() const
145-
{
146-
return HexStr(obfuscate_key);
147-
}
148-
149144
CDBIterator::~CDBIterator() { delete piter; }
150145
bool CDBIterator::Valid() { return piter->Valid(); }
151146
void CDBIterator::SeekToFirst() { piter->SeekToFirst(); }

src/dbwrapper.h

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -268,12 +268,6 @@ class CDBWrapper
268268
* Accessor for obfuscate_key.
269269
*/
270270
const std::vector<unsigned char>& GetObfuscateKey() const;
271-
272-
/**
273-
* Return the obfuscate_key as a hex-formatted string.
274-
*/
275-
std::string GetObfuscateKeyHex() const;
276-
277271
};
278272

279273
#endif // BITCOIN_DBWRAPPER_H

0 commit comments

Comments
 (0)