]> git.ipfire.org Git - thirdparty/tor.git/commitdiff
Use raw_assert in ht.h
authorNick Mathewson <nickm@torproject.org>
Mon, 16 Dec 2019 17:57:27 +0000 (12:57 -0500)
committerNick Mathewson <nickm@torproject.org>
Thu, 9 Jan 2020 12:30:35 +0000 (07:30 -0500)
Also, include torerr.h from ht.h if we are using raw_assert.

Otherwise, our includes need to be ordered so that ht.h comes after
util_log.h.

src/ext/ht.h

index bb5604131b8b9b454b3808d5c4b3325192b4d5cd..9d4add1936069273f96fbda7c5abe6445b64a090 100644 (file)
@@ -226,7 +226,8 @@ ht_string_hash(const char *s)
        (x) = HT_NEXT(name, head, x))
 
 #ifndef HT_NDEBUG
-#define HT_ASSERT_(x) tor_assert(x)
+#include "lib/err/torerr.h"
+#define HT_ASSERT_(x) raw_assert(x)
 #else
 #define HT_ASSERT_(x) (void)0
 #endif