From: George Kadianakis Date: Mon, 30 Sep 2019 10:56:51 +0000 (+0300) Subject: Merge branch 'tor-github/pr/1346' X-Git-Tag: tor-0.4.2.2-alpha~22 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=9318682109c5b8742bc868f3d30cb5cd39095f98;p=thirdparty%2Ftor.git Merge branch 'tor-github/pr/1346' --- 9318682109c5b8742bc868f3d30cb5cd39095f98 diff --cc src/app/config/config.c index 6ee818ab0c,2416da2b26..451593a5fa --- a/src/app/config/config.c +++ b/src/app/config/config.c @@@ -1197,9 -1187,28 +1197,13 @@@ init_protocol_warning_severity_level(vo static void cleanup_protocol_warning_severity_level(void) { - atomic_counter_destroy(&protocol_warning_severity_level); + /* Destroying a locked mutex is undefined behaviour. This mutex may be + * locked, because multiple threads can access it. But we need to destroy + * it, otherwise re-initialisation will trigger undefined behaviour. + * See #31735 for details. */ + atomic_counter_destroy(&protocol_warning_severity_level); } -/** List of default directory authorities */ - -static const char *default_authorities[] = { -#include "auth_dirs.inc" - NULL -}; - -/** List of fallback directory authorities. The list is generated by opt-in of - * relays that meet certain stability criteria. - */ -static const char *default_fallbacks[] = { -#include "fallback_dirs.inc" - NULL -}; - /** Add the default directory authorities directly into the trusted dir list, * but only add them insofar as they share bits with type. * Each authority's bits are restricted to the bits shared with type.