Merge remote-tracking branch 'tlyu-github/ticket28731-035' into maint-0.3.5

This commit is contained in:
Nick Mathewson 2018-12-13 18:57:00 -05:00
commit 94a7998158
2 changed files with 7 additions and 3 deletions

4
changes/ticket28731 Normal file
View File

@ -0,0 +1,4 @@
o Minor features (bootstrap):
- Add the bootstrap tag name to the log messages, so people
troubleshooting connection problems can look up a symbol instead
of a number. Closes ticket 28731.

View File

@ -7153,7 +7153,7 @@ control_event_bootstrap_core(int loglevel, bootstrap_status_t status,
status = progress; status = progress;
tor_log(loglevel, LD_CONTROL, tor_log(loglevel, LD_CONTROL,
"Bootstrapped %d%%: %s", status, summary); "Bootstrapped %d%% (%s): %s", status, tag, summary);
tor_snprintf(buf, sizeof(buf), tor_snprintf(buf, sizeof(buf),
"BOOTSTRAP PROGRESS=%d TAG=%s SUMMARY=\"%s\"", "BOOTSTRAP PROGRESS=%d TAG=%s SUMMARY=\"%s\"",
status, tag, summary); status, tag, summary);
@ -7309,9 +7309,9 @@ control_event_bootstrap_problem(const char *warn, const char *reason,
hostaddr = tor_strdup("?"); hostaddr = tor_strdup("?");
log_fn(severity, log_fn(severity,
LD_CONTROL, "Problem bootstrapping. Stuck at %d%%: %s. (%s; %s; " LD_CONTROL, "Problem bootstrapping. Stuck at %d%% (%s): %s. (%s; %s; "
"count %d; recommendation %s; host %s at %s)", "count %d; recommendation %s; host %s at %s)",
status, summary, warn, reason, status, tag, summary, warn, reason,
bootstrap_problems, recommendation, bootstrap_problems, recommendation,
or_id, hostaddr); or_id, hostaddr);