summaryrefslogtreecommitdiff
path: root/src/common/util.h
diff options
context:
space:
mode:
authorNick Mathewson <nickm@torproject.org>2018-06-20 13:02:05 -0400
committerNick Mathewson <nickm@torproject.org>2018-06-20 15:08:06 -0400
commit5ecd1fec1583b8aa865ac5cae0cece42451395bd (patch)
treef9645884a611826dc811fe159c17fd873b98768b /src/common/util.h
parent8865972a0b18a2fdcf42b55149989d0705c85577 (diff)
downloadtor-5ecd1fec1583b8aa865ac5cae0cece42451395bd.tar.gz
tor-5ecd1fec1583b8aa865ac5cae0cece42451395bd.zip
Move horrible-emergency handling into torerr.[ch]
Previously we had code like this for bad things happening from signal handlers, but it makes sense to use the same logic to handle cases when something is happening at a level too low for log.c to be involved. My raw_assert*() stuff now uses this code.
Diffstat (limited to 'src/common/util.h')
-rw-r--r--src/common/util.h4
1 files changed, 1 insertions, 3 deletions
diff --git a/src/common/util.h b/src/common/util.h
index 7921357ac5..a5e6c4d462 100644
--- a/src/common/util.h
+++ b/src/common/util.h
@@ -22,6 +22,7 @@
/* for the correct alias to struct stat */
#include <sys/stat.h>
#endif
+#include "common/torerr.h"
#include "common/util_bug.h"
#ifndef O_BINARY
@@ -522,9 +523,6 @@ int32_t tor_weak_random_range(tor_weak_rng_t *rng, int32_t top);
* <b>n</b> */
#define tor_weak_random_one_in_n(rng, n) (0==tor_weak_random_range((rng),(n)))
-int format_hex_number_sigsafe(unsigned long x, char *buf, int max_len);
-int format_dec_number_sigsafe(unsigned long x, char *buf, int max_len);
-
#ifdef UTIL_PRIVATE
/* Prototypes for private functions only used by util.c (and unit tests) */