aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--changes/RemoveLogHeader4
-rw-r--r--src/common/Makefile.am2
-rw-r--r--src/common/address.c2
-rw-r--r--src/common/aes.c2
-rw-r--r--src/common/compat.c2
-rw-r--r--src/common/compat_libevent.c2
-rw-r--r--src/common/container.c2
-rw-r--r--src/common/crypto.c2
-rw-r--r--src/common/log.c2
-rw-r--r--src/common/memarea.c2
-rw-r--r--src/common/mempool.c2
-rw-r--r--src/common/torgzip.c2
-rw-r--r--src/common/torlog.h (renamed from src/common/log.h)0
-rw-r--r--src/common/tortls.c2
-rw-r--r--src/common/util.c2
-rw-r--r--src/or/buffers.c2
-rw-r--r--src/or/or.h2
-rw-r--r--src/tools/tor-checkkey.c2
-rw-r--r--src/tools/tor-gencert.c2
-rw-r--r--src/tools/tor-resolve.c2
20 files changed, 22 insertions, 18 deletions
diff --git a/changes/RemoveLogHeader b/changes/RemoveLogHeader
new file mode 100644
index 0000000000..d93c9fffc0
--- /dev/null
+++ b/changes/RemoveLogHeader
@@ -0,0 +1,4 @@
+ o Code simplifications and refactoring:
+ - Rename the "log.h" header to "torlog.h" so as to conflict with fewer
+ system headers.
+
diff --git a/src/common/Makefile.am b/src/common/Makefile.am
index eecfeb83fe..b1e03cd710 100644
--- a/src/common/Makefile.am
+++ b/src/common/Makefile.am
@@ -16,7 +16,7 @@ libor_a_SOURCES = address.c log.c util.c compat.c container.c mempool.c \
libor_crypto_a_SOURCES = crypto.c aes.c tortls.c torgzip.c
libor_event_a_SOURCES = compat_libevent.c
-noinst_HEADERS = address.h log.h crypto.h util.h compat.h aes.h torint.h tortls.h strlcpy.c strlcat.c torgzip.h container.h ht.h mempool.h memarea.h ciphers.inc compat_libevent.h tortls_states.h
+noinst_HEADERS = address.h torlog.h crypto.h util.h compat.h aes.h torint.h tortls.h strlcpy.c strlcat.c torgzip.h container.h ht.h mempool.h memarea.h ciphers.inc compat_libevent.h tortls_states.h
common_sha1.i: $(libor_SOURCES) $(libor_crypto_a_SOURCES) $(noinst_HEADERS)
if test "@SHA1SUM@" != none; then \
diff --git a/src/common/address.c b/src/common/address.c
index 4569373f3b..c35f04c18b 100644
--- a/src/common/address.c
+++ b/src/common/address.c
@@ -12,7 +12,7 @@
#include "compat.h"
#include "util.h"
#include "address.h"
-#include "log.h"
+#include "torlog.h"
#ifdef MS_WINDOWS
#include <process.h>
diff --git a/src/common/aes.c b/src/common/aes.c
index 2b6f0234b7..a17328317e 100644
--- a/src/common/aes.c
+++ b/src/common/aes.c
@@ -21,7 +21,7 @@
#include "compat.h"
#include "aes.h"
#include "util.h"
-#include "log.h"
+#include "torlog.h"
/* We have 3 strategies for getting AES: Via OpenSSL's AES_encrypt function,
* via OpenSSL's EVP_EncryptUpdate function, or via the built-in AES
diff --git a/src/common/compat.c b/src/common/compat.c
index 7b79c5cc3e..ebe8c03e33 100644
--- a/src/common/compat.c
+++ b/src/common/compat.c
@@ -88,7 +88,7 @@
#include <sys/prctl.h>
#endif
-#include "log.h"
+#include "torlog.h"
#include "util.h"
#include "container.h"
#include "address.h"
diff --git a/src/common/compat_libevent.c b/src/common/compat_libevent.c
index 1532392279..5cdd687cf0 100644
--- a/src/common/compat_libevent.c
+++ b/src/common/compat_libevent.c
@@ -15,7 +15,7 @@
#include "compat_libevent.h"
#include "util.h"
-#include "log.h"
+#include "torlog.h"
#ifdef HAVE_EVENT2_EVENT_H
#include <event2/event.h>
diff --git a/src/common/container.c b/src/common/container.c
index ab5a9b0325..72f3470344 100644
--- a/src/common/container.c
+++ b/src/common/container.c
@@ -13,7 +13,7 @@
#include "compat.h"
#include "util.h"
-#include "log.h"
+#include "torlog.h"
#include "container.h"
#include "crypto.h"
diff --git a/src/common/crypto.c b/src/common/crypto.c
index 1d75555b2f..bfb81d3ccd 100644
--- a/src/common/crypto.c
+++ b/src/common/crypto.c
@@ -50,7 +50,7 @@
#define CRYPTO_PRIVATE
#include "crypto.h"
-#include "../common/log.h"
+#include "../common/torlog.h"
#include "aes.h"
#include "../common/util.h"
#include "container.h"
diff --git a/src/common/log.c b/src/common/log.c
index 6bf94721f8..b639e7a781 100644
--- a/src/common/log.c
+++ b/src/common/log.c
@@ -33,7 +33,7 @@
#include "compat.h"
#include "util.h"
#define LOG_PRIVATE
-#include "log.h"
+#include "torlog.h"
#include "container.h"
#define TRUNCATED_STR "[...truncated]"
diff --git a/src/common/memarea.c b/src/common/memarea.c
index 0402e5f208..77579e63be 100644
--- a/src/common/memarea.c
+++ b/src/common/memarea.c
@@ -11,7 +11,7 @@
#include "memarea.h"
#include "util.h"
#include "compat.h"
-#include "log.h"
+#include "torlog.h"
/** If true, we try to detect any attempts to write beyond the length of a
* memarea. */
diff --git a/src/common/mempool.c b/src/common/mempool.c
index 256388a9fd..c795d83f0c 100644
--- a/src/common/mempool.c
+++ b/src/common/mempool.c
@@ -65,7 +65,7 @@
#include "orconfig.h"
#include "util.h"
#include "compat.h"
-#include "log.h"
+#include "torlog.h"
#define ALLOC(x) tor_malloc(x)
#define FREE(x) tor_free(x)
#define ASSERT(x) tor_assert(x)
diff --git a/src/common/torgzip.c b/src/common/torgzip.c
index 9ebddf07b7..a247d6c177 100644
--- a/src/common/torgzip.c
+++ b/src/common/torgzip.c
@@ -20,7 +20,7 @@
#include "torint.h"
#include "util.h"
-#include "log.h"
+#include "torlog.h"
#include "torgzip.h"
/* zlib 1.2.4 and 1.2.5 do some "clever" things with macros. Instead of
diff --git a/src/common/log.h b/src/common/torlog.h
index 21219569e3..21219569e3 100644
--- a/src/common/log.h
+++ b/src/common/torlog.h
diff --git a/src/common/tortls.c b/src/common/tortls.c
index 6732d55b8a..b3c91a6ca6 100644
--- a/src/common/tortls.c
+++ b/src/common/tortls.c
@@ -38,7 +38,7 @@
#include "crypto.h"
#include "tortls.h"
#include "util.h"
-#include "log.h"
+#include "torlog.h"
#include "container.h"
#include "ht.h"
#include <string.h>
diff --git a/src/common/util.c b/src/common/util.c
index 8531d12eba..6830ef3aa4 100644
--- a/src/common/util.c
+++ b/src/common/util.c
@@ -15,7 +15,7 @@
#include "orconfig.h"
#include "util.h"
-#include "log.h"
+#include "torlog.h"
#undef log
#include "crypto.h"
#include "torint.h"
diff --git a/src/or/buffers.c b/src/or/buffers.c
index 970c1888c1..c4ebc8135f 100644
--- a/src/or/buffers.c
+++ b/src/or/buffers.c
@@ -13,7 +13,7 @@
#define BUFFERS_PRIVATE
#include "or.h"
#include "../common/util.h"
-#include "../common/log.h"
+#include "../common/torlog.h"
#ifdef HAVE_UNISTD_H
#include <unistd.h>
#endif
diff --git a/src/or/or.h b/src/or/or.h
index 60987698b4..2124d457ef 100644
--- a/src/or/or.h
+++ b/src/or/or.h
@@ -82,7 +82,7 @@
#include "crypto.h"
#include "tortls.h"
-#include "../common/log.h"
+#include "../common/torlog.h"
#include "compat.h"
#include "container.h"
#include "util.h"
diff --git a/src/tools/tor-checkkey.c b/src/tools/tor-checkkey.c
index a244124991..94c8cbd44c 100644
--- a/src/tools/tor-checkkey.c
+++ b/src/tools/tor-checkkey.c
@@ -6,7 +6,7 @@
#include <stdio.h>
#include <stdlib.h>
#include "crypto.h"
-#include "log.h"
+#include "torlog.h"
#include "../common/util.h"
#include "compat.h"
#include <openssl/bn.h>
diff --git a/src/tools/tor-gencert.c b/src/tools/tor-gencert.c
index 13a640cb8b..bc99c24bd7 100644
--- a/src/tools/tor-gencert.c
+++ b/src/tools/tor-gencert.c
@@ -29,7 +29,7 @@
#include "compat.h"
#include "../common/util.h"
-#include "../common/log.h"
+#include "../common/torlog.h"
#include "crypto.h"
#include "address.h"
diff --git a/src/tools/tor-resolve.c b/src/tools/tor-resolve.c
index 2639d9e599..f5b0becaff 100644
--- a/src/tools/tor-resolve.c
+++ b/src/tools/tor-resolve.c
@@ -8,7 +8,7 @@
#include "compat.h"
#include "../common/util.h"
#include "address.h"
-#include "../common/log.h"
+#include "../common/torlog.h"
#include <stdio.h>
#include <stdlib.h>