Skip to content

Commit

Permalink
dbwrapper: Remove CDBWrapper::GetObfuscateKeyHex
Browse files Browse the repository at this point in the history
It is an unnecessary method as it is used only two times
and only internally, and the whole implementation is
HexStr(obfuscate_key).
  • Loading branch information
laanwj committed Apr 23, 2016
1 parent 74f7b12 commit 878bf48
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 13 deletions.
9 changes: 2 additions & 7 deletions src/dbwrapper.cpp
Expand Up @@ -84,10 +84,10 @@ CDBWrapper::CDBWrapper(const boost::filesystem::path& path, size_t nCacheSize, b
Write(OBFUSCATE_KEY_KEY, new_key);
obfuscate_key = new_key;

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

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

CDBWrapper::~CDBWrapper()
Expand Down Expand Up @@ -141,11 +141,6 @@ const std::vector<unsigned char>& CDBWrapper::GetObfuscateKey() const
return obfuscate_key;
}

std::string CDBWrapper::GetObfuscateKeyHex() const
{
return HexStr(obfuscate_key);
}

CDBIterator::~CDBIterator() { delete piter; }
bool CDBIterator::Valid() { return piter->Valid(); }
void CDBIterator::SeekToFirst() { piter->SeekToFirst(); }
Expand Down
6 changes: 0 additions & 6 deletions src/dbwrapper.h
Expand Up @@ -268,12 +268,6 @@ class CDBWrapper
* Accessor for obfuscate_key.
*/
const std::vector<unsigned char>& GetObfuscateKey() const;

/**
* Return the obfuscate_key as a hex-formatted string.
*/
std::string GetObfuscateKeyHex() const;

};

#endif // BITCOIN_DBWRAPPER_H
Expand Down

0 comments on commit 878bf48

Please sign in to comment.