]> git.ipfire.org Git - thirdparty/tor.git/commitdiff
Merge branch 'tor-github/pr/1346'
authorGeorge Kadianakis <desnacked@riseup.net>
Mon, 30 Sep 2019 10:56:51 +0000 (13:56 +0300)
committerGeorge Kadianakis <desnacked@riseup.net>
Mon, 30 Sep 2019 10:56:51 +0000 (13:56 +0300)
1  2 
src/app/config/config.c
src/feature/relay/router.c
src/lib/crypt_ops/crypto_openssl_mgt.c
src/lib/thread/compat_threads.c

index 6ee818ab0c68ec16d6147c72dfbd4c5e5ceeacd6,2416da2b26eaa38237f5a5284823d0572bb7b085..451593a5fa4194d74af2fc25f6e942657a115881
@@@ -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 <b>type</b>.
   * Each authority's bits are restricted to the bits shared with <b>type</b>.
Simple merge
Simple merge