mirror of
https://github.com/bitcoin/bitcoin.git
synced 2025-02-23 07:15:29 +01:00
Merge #11794: Prefix leveldb debug logging
9b80fc1
Prefix leveldb debug logging (Wladimir J. van der Laan)
Pull request description:
Add leveldb: prefix to leveldb debug logging lines.
leveldb debug messages come in various scary flavors such as:
2017-11-30 08:26:31 leveldb: Recovering log #26
2017-11-30 08:26:31 leveldb: Level-0 table #28: started
2017-11-30 08:26:31 leveldb: Level-0 table #28: 597 bytes OK
2017-11-30 08:26:31 leveldb: Delete type=0 #26
2017-11-30 08:26:31 leveldb: Delete type=3 #24
so it's reasonably important to mark them as coming from leveldb internals and not from consensus validation wallet or such.
This is consistent with the `libevent:` prefix for libevent messages.
(this only affects `-debug=leveldb` or `-debug=1` otherwise you won't see them in the first place)
Tree-SHA512: 074eba00d39c6378b9e14d03aa2c551b4e3fc7bffdd5a1a0ba2498b44bcc77071d47735be09493286056053f0cca625c5cbaad7ad1ddb9d902d30e7cd316d9d2
This commit is contained in:
commit
dd49862a70
1 changed files with 1 additions and 1 deletions
|
@ -64,7 +64,7 @@ public:
|
||||||
|
|
||||||
assert(p <= limit);
|
assert(p <= limit);
|
||||||
base[std::min(bufsize - 1, (int)(p - base))] = '\0';
|
base[std::min(bufsize - 1, (int)(p - base))] = '\0';
|
||||||
LogPrintStr(base);
|
LogPrintf("leveldb: %s", base);
|
||||||
if (base != buffer) {
|
if (base != buffer) {
|
||||||
delete[] base;
|
delete[] base;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Reference in a new issue