Skip to content

Commit 4531fc4

Browse files
committed
torcontrol: only output disconnect if -debug=tor
1 parent a775182 commit 4531fc4

File tree

2 files changed

+4
-2
lines changed

2 files changed

+4
-2
lines changed

src/init.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -441,7 +441,7 @@ std::string HelpMessage(HelpMessageMode mode)
441441
strUsage += HelpMessageOpt("-limitdescendantcount=<n>", strprintf("Do not accept transactions if any ancestor would have <n> or more in-mempool descendants (default: %u)", DEFAULT_DESCENDANT_LIMIT));
442442
strUsage += HelpMessageOpt("-limitdescendantsize=<n>", strprintf("Do not accept transactions if any ancestor would have more than <n> kilobytes of in-mempool descendants (default: %u).", DEFAULT_DESCENDANT_SIZE_LIMIT));
443443
}
444-
string debugCategories = "addrman, alert, bench, coindb, db, lock, rand, rpc, selectcoins, mempool, mempoolrej, net, proxy, prune, http, libevent, zmq"; // Don't translate these and qt below
444+
string debugCategories = "addrman, alert, bench, coindb, db, lock, rand, rpc, selectcoins, mempool, mempoolrej, net, proxy, prune, http, libevent, tor, zmq"; // Don't translate these and qt below
445445
if (mode == HMM_BITCOIN_QT)
446446
debugCategories += ", qt";
447447
strUsage += HelpMessageOpt("-debug=<category>", strprintf(_("Output debugging information (default: %u, supplying <category> is optional)"), 0) + ". " +

src/torcontrol.cpp

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -617,7 +617,9 @@ void TorController::disconnected_cb(TorControlConnection& conn)
617617
service = CService();
618618
if (!reconnect)
619619
return;
620-
LogPrintf("tor: Disconnected from Tor control port %s, trying to reconnect\n", target);
620+
621+
LogPrint("tor", "tor: Disconnected from Tor control port %s, trying to reconnect\n", target);
622+
621623
// Single-shot timer for reconnect. Use exponential backoff.
622624
struct timeval time = MillisToTimeval(int64_t(reconnect_timeout * 1000.0));
623625
reconnect_ev = event_new(base, -1, 0, reconnect_cb, this);

0 commit comments

Comments
 (0)