[Author Prev][Author Next][Thread Prev][Thread Next][Author Index][Thread Index]

[tor-commits] [tor/master] Replace several C identifiers.



commit 8c23ac4ae713f7cce7cd7541d2ae635c50c7c062
Author: teor <teor@xxxxxxxxxxxxxx>
Date:   Fri Dec 20 13:27:58 2019 +1000

    Replace several C identifiers.
    
    This is an automated commit, generated by this command:
    
    ./scripts/maint/rename_c_identifier.py \
            EXPOSE_CLEAN_BACKTRACE BACKTRACE_PRIVATE \
            TOR_CHANNEL_INTERNAL_ CHANNEL_OBJECT_PRIVATE \
            CHANNEL_PRIVATE_ CHANNEL_FILE_PRIVATE \
            EXPOSE_ROUTERDESC_TOKEN_TABLE ROUTERDESC_TOKEN_TABLE_PRIVATE \
            SCHEDULER_PRIVATE_ SCHEDULER_PRIVATE
---
 src/core/mainloop/connection.c      | 2 +-
 src/core/or/channel.c               | 4 ++--
 src/core/or/channel.h               | 8 ++++----
 src/core/or/channelpadding.c        | 4 ++--
 src/core/or/channeltls.c            | 2 +-
 src/core/or/channeltls.h            | 4 ++--
 src/core/or/connection_or.c         | 2 +-
 src/core/or/scheduler.c             | 4 ++--
 src/core/or/scheduler.h             | 4 ++--
 src/core/or/scheduler_kist.c        | 4 ++--
 src/core/or/scheduler_vanilla.c     | 4 ++--
 src/feature/dirparse/policy_parse.c | 2 +-
 src/feature/dirparse/routerparse.c  | 2 +-
 src/feature/dirparse/routerparse.h  | 2 +-
 src/lib/err/backtrace.c             | 2 +-
 src/lib/err/backtrace.h             | 4 ++--
 src/lib/sandbox/sandbox.c           | 2 +-
 src/test/test_channel.c             | 4 ++--
 src/test/test_channelpadding.c      | 2 +-
 src/test/test_channeltls.c          | 2 +-
 src/test/test_circuitlist.c         | 2 +-
 src/test/test_circuitmux.c          | 2 +-
 src/test/test_circuitpadding.c      | 2 +-
 src/test/test_circuitstats.c        | 2 +-
 src/test/test_controller_events.c   | 2 +-
 src/test/test_dos.c                 | 2 +-
 src/test/test_hs_cache.c            | 2 +-
 src/test/test_hs_client.c           | 2 +-
 src/test/test_hs_service.c          | 2 +-
 src/test/test_link_handshake.c      | 2 +-
 src/test/test_scheduler.c           | 6 +++---
 31 files changed, 45 insertions(+), 45 deletions(-)

diff --git a/src/core/mainloop/connection.c b/src/core/mainloop/connection.c
index 3693e1d71..50fd12319 100644
--- a/src/core/mainloop/connection.c
+++ b/src/core/mainloop/connection.c
@@ -65,7 +65,7 @@
  * Define this so we get channel internal functions, since we're implementing
  * part of a subclass (channel_tls_t).
  */
-#define TOR_CHANNEL_INTERNAL_
+#define CHANNEL_OBJECT_PRIVATE
 #include "app/config/config.h"
 #include "core/mainloop/connection.h"
 #include "core/mainloop/mainloop.h"
diff --git a/src/core/or/channel.c b/src/core/or/channel.c
index 1641a9680..2faf63875 100644
--- a/src/core/or/channel.c
+++ b/src/core/or/channel.c
@@ -52,10 +52,10 @@
  * Define this so channel.h gives us things only channel_t subclasses
  * should touch.
  */
-#define TOR_CHANNEL_INTERNAL_
+#define CHANNEL_OBJECT_PRIVATE
 
 /* This one's for stuff only channel.c and the test suite should see */
-#define CHANNEL_PRIVATE_
+#define CHANNEL_FILE_PRIVATE
 
 #include "core/or/or.h"
 #include "app/config/config.h"
diff --git a/src/core/or/channel.h b/src/core/or/channel.h
index 7f5bd9bf2..0f6fa228d 100644
--- a/src/core/or/channel.h
+++ b/src/core/or/channel.h
@@ -563,13 +563,13 @@ void channel_free_all(void);
 void channel_dumpstats(int severity);
 void channel_listener_dumpstats(int severity);
 
-#ifdef TOR_CHANNEL_INTERNAL_
+#ifdef CHANNEL_OBJECT_PRIVATE
 
-#ifdef CHANNEL_PRIVATE_
+#ifdef CHANNEL_FILE_PRIVATE
 
 STATIC void channel_add_to_digest_map(channel_t *chan);
 
-#endif /* defined(CHANNEL_PRIVATE_) */
+#endif /* defined(CHANNEL_FILE_PRIVATE) */
 
 /* Channel operations for subclasses and internal use only */
 
@@ -648,7 +648,7 @@ void channel_notify_flushed(channel_t *chan);
 /* Handle stuff we need to do on open like notifying circuits */
 void channel_do_open_actions(channel_t *chan);
 
-#endif /* defined(TOR_CHANNEL_INTERNAL_) */
+#endif /* defined(CHANNEL_OBJECT_PRIVATE) */
 
 /* Helper functions to perform operations on channels */
 
diff --git a/src/core/or/channelpadding.c b/src/core/or/channelpadding.c
index 2b8314db8..9c95858bb 100644
--- a/src/core/or/channelpadding.c
+++ b/src/core/or/channelpadding.c
@@ -9,9 +9,9 @@
  * @brief Link-level padding code.
  **/
 
-/* TOR_CHANNEL_INTERNAL_ define needed for an O(1) implementation of
+/* CHANNEL_OBJECT_PRIVATE define needed for an O(1) implementation of
  * channelpadding_channel_to_channelinfo() */
-#define TOR_CHANNEL_INTERNAL_
+#define CHANNEL_OBJECT_PRIVATE
 
 #include "core/or/or.h"
 #include "core/or/channel.h"
diff --git a/src/core/or/channeltls.c b/src/core/or/channeltls.c
index e9497651e..a5710c7f4 100644
--- a/src/core/or/channeltls.c
+++ b/src/core/or/channeltls.c
@@ -34,7 +34,7 @@
  * Define this so channel.h gives us things only channel_t subclasses
  * should touch.
  */
-#define TOR_CHANNEL_INTERNAL_
+#define CHANNEL_OBJECT_PRIVATE
 
 #define CHANNELTLS_PRIVATE
 
diff --git a/src/core/or/channeltls.h b/src/core/or/channeltls.h
index ff703a497..720adbdd2 100644
--- a/src/core/or/channeltls.h
+++ b/src/core/or/channeltls.h
@@ -22,7 +22,7 @@ struct curve25519_public_key_t;
 
 #define TLS_CHAN_MAGIC 0x8a192427U
 
-#ifdef TOR_CHANNEL_INTERNAL_
+#ifdef CHANNEL_OBJECT_PRIVATE
 
 struct channel_tls_t {
   /* Base channel_t struct */
@@ -31,7 +31,7 @@ struct channel_tls_t {
   or_connection_t *conn;
 };
 
-#endif /* defined(TOR_CHANNEL_INTERNAL_) */
+#endif /* defined(CHANNEL_OBJECT_PRIVATE) */
 
 channel_t * channel_tls_connect(const tor_addr_t *addr, uint16_t port,
                                 const char *id_digest,
diff --git a/src/core/or/connection_or.c b/src/core/or/connection_or.c
index 4c93351e3..24a4af045 100644
--- a/src/core/or/connection_or.c
+++ b/src/core/or/connection_or.c
@@ -27,7 +27,7 @@
  * Define this so we get channel internal functions, since we're implementing
  * part of a subclass (channel_tls_t).
  */
-#define TOR_CHANNEL_INTERNAL_
+#define CHANNEL_OBJECT_PRIVATE
 #define CONNECTION_OR_PRIVATE
 #define ORCONN_EVENT_PRIVATE
 #include "core/or/channel.h"
diff --git a/src/core/or/scheduler.c b/src/core/or/scheduler.c
index 5b1cd90ae..023e9bf1b 100644
--- a/src/core/or/scheduler.c
+++ b/src/core/or/scheduler.c
@@ -5,12 +5,12 @@
 #include "app/config/config.h"
 
 #include "lib/evloop/compat_libevent.h"
-#define SCHEDULER_PRIVATE_
+#define SCHEDULER_PRIVATE
 #define SCHEDULER_KIST_PRIVATE
 #include "core/or/scheduler.h"
 #include "core/mainloop/mainloop.h"
 #include "lib/buf/buffers.h"
-#define TOR_CHANNEL_INTERNAL_
+#define CHANNEL_OBJECT_PRIVATE
 #include "core/or/channeltls.h"
 
 #include "core/or/or_connection_st.h"
diff --git a/src/core/or/scheduler.h b/src/core/or/scheduler.h
index b82f8730b..8b3995e61 100644
--- a/src/core/or/scheduler.h
+++ b/src/core/or/scheduler.h
@@ -136,7 +136,7 @@ MOCK_DECL(void, scheduler_channel_has_waiting_cells, (channel_t *chan));
  * These functions are only visible to the scheduling system, the current
  * scheduler implementation, and tests.
  *****************************************************************************/
-#ifdef SCHEDULER_PRIVATE_
+#ifdef SCHEDULER_PRIVATE
 
 /*********************************
  * Defined in scheduler.c
@@ -212,7 +212,7 @@ extern int32_t sched_run_interval;
 
 scheduler_t *get_vanilla_scheduler(void);
 
-#endif /* defined(SCHEDULER_PRIVATE_) */
+#endif /* defined(SCHEDULER_PRIVATE) */
 
 #endif /* !defined(TOR_SCHEDULER_H) */
 
diff --git a/src/core/or/scheduler_kist.c b/src/core/or/scheduler_kist.c
index 660c222a3..a074b66ae 100644
--- a/src/core/or/scheduler_kist.c
+++ b/src/core/or/scheduler_kist.c
@@ -13,10 +13,10 @@
 #include "app/config/config.h"
 #include "core/mainloop/connection.h"
 #include "feature/nodelist/networkstatus.h"
-#define TOR_CHANNEL_INTERNAL_
+#define CHANNEL_OBJECT_PRIVATE
 #include "core/or/channel.h"
 #include "core/or/channeltls.h"
-#define SCHEDULER_PRIVATE_
+#define SCHEDULER_PRIVATE
 #include "core/or/scheduler.h"
 #include "lib/math/fp.h"
 
diff --git a/src/core/or/scheduler_vanilla.c b/src/core/or/scheduler_vanilla.c
index bd84a4e4e..fb8cd65a8 100644
--- a/src/core/or/scheduler_vanilla.c
+++ b/src/core/or/scheduler_vanilla.c
@@ -8,9 +8,9 @@
 
 #include "core/or/or.h"
 #include "app/config/config.h"
-#define TOR_CHANNEL_INTERNAL_
+#define CHANNEL_OBJECT_PRIVATE
 #include "core/or/channel.h"
-#define SCHEDULER_PRIVATE_
+#define SCHEDULER_PRIVATE
 #include "core/or/scheduler.h"
 
 /*****************************************************************************
diff --git a/src/feature/dirparse/policy_parse.c b/src/feature/dirparse/policy_parse.c
index 7562ae409..cad623d56 100644
--- a/src/feature/dirparse/policy_parse.c
+++ b/src/feature/dirparse/policy_parse.c
@@ -9,7 +9,7 @@
  * \brief Code to parse address policies.
  **/
 
-#define  EXPOSE_ROUTERDESC_TOKEN_TABLE
+#define  ROUTERDESC_TOKEN_TABLE_PRIVATE
 
 #include "core/or/or.h"
 
diff --git a/src/feature/dirparse/routerparse.c b/src/feature/dirparse/routerparse.c
index f78c46f18..d4c0a11f1 100644
--- a/src/feature/dirparse/routerparse.c
+++ b/src/feature/dirparse/routerparse.c
@@ -50,7 +50,7 @@
  * </ul>
  **/
 
-#define EXPOSE_ROUTERDESC_TOKEN_TABLE
+#define ROUTERDESC_TOKEN_TABLE_PRIVATE
 
 #include "core/or/or.h"
 #include "app/config/config.h"
diff --git a/src/feature/dirparse/routerparse.h b/src/feature/dirparse/routerparse.h
index f9a13f216..f2e59f0f2 100644
--- a/src/feature/dirparse/routerparse.h
+++ b/src/feature/dirparse/routerparse.h
@@ -40,7 +40,7 @@ int find_single_ipv6_orport(const smartlist_t *list,
 void routerparse_init(void);
 void routerparse_free_all(void);
 
-#ifdef EXPOSE_ROUTERDESC_TOKEN_TABLE
+#ifdef ROUTERDESC_TOKEN_TABLE_PRIVATE
 extern const struct token_rule_t routerdesc_token_table[];
 #endif
 
diff --git a/src/lib/err/backtrace.c b/src/lib/err/backtrace.c
index ce8ddcd7c..62088c1f4 100644
--- a/src/lib/err/backtrace.c
+++ b/src/lib/err/backtrace.c
@@ -54,7 +54,7 @@
 
 #include "lib/cc/ctassert.h"
 
-#define EXPOSE_CLEAN_BACKTRACE
+#define BACKTRACE_PRIVATE
 #include "lib/err/backtrace.h"
 
 #if defined(HAVE_EXECINFO_H) && defined(HAVE_BACKTRACE) && \
diff --git a/src/lib/err/backtrace.h b/src/lib/err/backtrace.h
index 7e09a0a5a..21303105e 100644
--- a/src/lib/err/backtrace.h
+++ b/src/lib/err/backtrace.h
@@ -29,11 +29,11 @@ const char *get_tor_backtrace_version(void);
 #define log_backtrace(sev, dom, msg) \
   log_backtrace_impl((sev), (dom), (msg), tor_log)
 
-#ifdef EXPOSE_CLEAN_BACKTRACE
+#ifdef BACKTRACE_PRIVATE
 #if defined(HAVE_EXECINFO_H) && defined(HAVE_BACKTRACE) && \
   defined(HAVE_BACKTRACE_SYMBOLS_FD) && defined(HAVE_SIGACTION)
 void clean_backtrace(void **stack, size_t depth, const ucontext_t *ctx);
 #endif
-#endif /* defined(EXPOSE_CLEAN_BACKTRACE) */
+#endif /* defined(BACKTRACE_PRIVATE) */
 
 #endif /* !defined(TOR_BACKTRACE_H) */
diff --git a/src/lib/sandbox/sandbox.c b/src/lib/sandbox/sandbox.c
index 0b316e9c6..2429f30be 100644
--- a/src/lib/sandbox/sandbox.c
+++ b/src/lib/sandbox/sandbox.c
@@ -82,7 +82,7 @@
 #if defined(HAVE_EXECINFO_H) && defined(HAVE_BACKTRACE) && \
   defined(HAVE_BACKTRACE_SYMBOLS_FD) && defined(HAVE_SIGACTION)
 #define USE_BACKTRACE
-#define EXPOSE_CLEAN_BACKTRACE
+#define BACKTRACE_PRIVATE
 #include "lib/err/backtrace.h"
 #endif /* defined(HAVE_EXECINFO_H) && defined(HAVE_BACKTRACE) && ... */
 
diff --git a/src/test/test_channel.c b/src/test/test_channel.c
index 6a6bc9d81..035303279 100644
--- a/src/test/test_channel.c
+++ b/src/test/test_channel.c
@@ -1,8 +1,8 @@
 /* Copyright (c) 2013-2019, The Tor Project, Inc. */
 /* See LICENSE for licensing information */
 
-#define TOR_CHANNEL_INTERNAL_
-#define CHANNEL_PRIVATE_
+#define CHANNEL_OBJECT_PRIVATE
+#define CHANNEL_FILE_PRIVATE
 #include "core/or/or.h"
 #include "core/or/channel.h"
 /* For channel_note_destroy_not_pending */
diff --git a/src/test/test_channelpadding.c b/src/test/test_channelpadding.c
index 885246628..0c610efd9 100644
--- a/src/test/test_channelpadding.c
+++ b/src/test/test_channelpadding.c
@@ -1,7 +1,7 @@
 /* Copyright (c) 2016-2019, The Tor Project, Inc. */
 /* See LICENSE for licensing information */
 
-#define TOR_CHANNEL_INTERNAL_
+#define CHANNEL_OBJECT_PRIVATE
 #define MAINLOOP_PRIVATE
 #define NETWORKSTATUS_PRIVATE
 #define TOR_TIMERS_PRIVATE
diff --git a/src/test/test_channeltls.c b/src/test/test_channeltls.c
index 054d3910e..f41a58e0a 100644
--- a/src/test/test_channeltls.c
+++ b/src/test/test_channeltls.c
@@ -5,7 +5,7 @@
 
 #include <math.h>
 
-#define TOR_CHANNEL_INTERNAL_
+#define CHANNEL_OBJECT_PRIVATE
 #include "core/or/or.h"
 #include "lib/net/address.h"
 #include "lib/buf/buffers.h"
diff --git a/src/test/test_circuitlist.c b/src/test/test_circuitlist.c
index 5cebdbeda..d9a5927fd 100644
--- a/src/test/test_circuitlist.c
+++ b/src/test/test_circuitlist.c
@@ -1,7 +1,7 @@
 /* Copyright (c) 2013-2019, The Tor Project, Inc. */
 /* See LICENSE for licensing information */
 
-#define TOR_CHANNEL_INTERNAL_
+#define CHANNEL_OBJECT_PRIVATE
 #define CIRCUITBUILD_PRIVATE
 #define CIRCUITLIST_PRIVATE
 #define HS_CIRCUITMAP_PRIVATE
diff --git a/src/test/test_circuitmux.c b/src/test/test_circuitmux.c
index f0b046557..8ff1f9c9e 100644
--- a/src/test/test_circuitmux.c
+++ b/src/test/test_circuitmux.c
@@ -1,7 +1,7 @@
 /* Copyright (c) 2013-2019, The Tor Project, Inc. */
 /* See LICENSE for licensing information */
 
-#define TOR_CHANNEL_INTERNAL_
+#define CHANNEL_OBJECT_PRIVATE
 #define CIRCUITMUX_PRIVATE
 #define CIRCUITMUX_EWMA_PRIVATE
 #define RELAY_PRIVATE
diff --git a/src/test/test_circuitpadding.c b/src/test/test_circuitpadding.c
index 78a019de8..cfb24c032 100644
--- a/src/test/test_circuitpadding.c
+++ b/src/test/test_circuitpadding.c
@@ -1,4 +1,4 @@
-#define TOR_CHANNEL_INTERNAL_
+#define CHANNEL_OBJECT_PRIVATE
 #define TOR_TIMERS_PRIVATE
 #define CIRCUITPADDING_PRIVATE
 #define CIRCUITPADDING_MACHINES_PRIVATE
diff --git a/src/test/test_circuitstats.c b/src/test/test_circuitstats.c
index 9bfaabeb2..f554a781d 100644
--- a/src/test/test_circuitstats.c
+++ b/src/test/test_circuitstats.c
@@ -4,7 +4,7 @@
 #define CIRCUITBUILD_PRIVATE
 #define CIRCUITSTATS_PRIVATE
 #define CIRCUITLIST_PRIVATE
-#define CHANNEL_PRIVATE_
+#define CHANNEL_FILE_PRIVATE
 
 #include "core/or/or.h"
 #include "test/test.h"
diff --git a/src/test/test_controller_events.c b/src/test/test_controller_events.c
index 9267aa0e4..db4530ef4 100644
--- a/src/test/test_controller_events.c
+++ b/src/test/test_controller_events.c
@@ -2,7 +2,7 @@
 /* See LICENSE for licensing information */
 
 #define CONNECTION_PRIVATE
-#define TOR_CHANNEL_INTERNAL_
+#define CHANNEL_OBJECT_PRIVATE
 #define CONTROL_PRIVATE
 #define CONTROL_EVENTS_PRIVATE
 #define OCIRC_EVENT_PRIVATE
diff --git a/src/test/test_dos.c b/src/test/test_dos.c
index bda9908e6..7472da2af 100644
--- a/src/test/test_dos.c
+++ b/src/test/test_dos.c
@@ -2,7 +2,7 @@
 /* See LICENSE for licensing information */
 
 #define DOS_PRIVATE
-#define TOR_CHANNEL_INTERNAL_
+#define CHANNEL_OBJECT_PRIVATE
 #define CIRCUITLIST_PRIVATE
 
 #include "core/or/or.h"
diff --git a/src/test/test_hs_cache.c b/src/test/test_hs_cache.c
index c39a4b644..fd673c999 100644
--- a/src/test/test_hs_cache.c
+++ b/src/test/test_hs_cache.c
@@ -10,7 +10,7 @@
 #define DIRCACHE_PRIVATE
 #define DIRCLIENT_PRIVATE
 #define HS_CACHE_PRIVATE
-#define TOR_CHANNEL_INTERNAL_
+#define CHANNEL_OBJECT_PRIVATE
 
 #include "trunnel/ed25519_cert.h"
 #include "feature/hs/hs_cache.h"
diff --git a/src/test/test_hs_client.c b/src/test/test_hs_client.c
index 515462e4b..b3cf79848 100644
--- a/src/test/test_hs_client.c
+++ b/src/test/test_hs_client.c
@@ -10,7 +10,7 @@
 #define CRYPTO_PRIVATE
 #define MAINLOOP_PRIVATE
 #define HS_CLIENT_PRIVATE
-#define TOR_CHANNEL_INTERNAL_
+#define CHANNEL_OBJECT_PRIVATE
 #define CIRCUITBUILD_PRIVATE
 #define CIRCUITLIST_PRIVATE
 #define CONNECTION_PRIVATE
diff --git a/src/test/test_hs_service.c b/src/test/test_hs_service.c
index daed1cda8..8bf0405f7 100644
--- a/src/test/test_hs_service.c
+++ b/src/test/test_hs_service.c
@@ -19,7 +19,7 @@
 #define MAINLOOP_PRIVATE
 #define NETWORKSTATUS_PRIVATE
 #define STATEFILE_PRIVATE
-#define TOR_CHANNEL_INTERNAL_
+#define CHANNEL_OBJECT_PRIVATE
 #define HS_CLIENT_PRIVATE
 #define CRYPT_PATH_PRIVATE
 
diff --git a/src/test/test_link_handshake.c b/src/test/test_link_handshake.c
index 7d79eb1ed..f22b9920b 100644
--- a/src/test/test_link_handshake.c
+++ b/src/test/test_link_handshake.c
@@ -5,7 +5,7 @@
 
 #define CHANNELTLS_PRIVATE
 #define CONNECTION_PRIVATE
-#define TOR_CHANNEL_INTERNAL_
+#define CHANNEL_OBJECT_PRIVATE
 #define TORTLS_PRIVATE
 
 #include "core/or/or.h"
diff --git a/src/test/test_scheduler.c b/src/test/test_scheduler.c
index 39c4963fc..3d37cc837 100644
--- a/src/test/test_scheduler.c
+++ b/src/test/test_scheduler.c
@@ -6,8 +6,8 @@
 #include <math.h>
 
 #define SCHEDULER_KIST_PRIVATE
-#define TOR_CHANNEL_INTERNAL_
-#define CHANNEL_PRIVATE_
+#define CHANNEL_OBJECT_PRIVATE
+#define CHANNEL_FILE_PRIVATE
 #include "core/or/or.h"
 #include "app/config/config.h"
 #include "lib/evloop/compat_libevent.h"
@@ -15,7 +15,7 @@
 #include "core/or/channeltls.h"
 #include "core/mainloop/connection.h"
 #include "feature/nodelist/networkstatus.h"
-#define SCHEDULER_PRIVATE_
+#define SCHEDULER_PRIVATE
 #include "core/or/scheduler.h"
 
 /* Test suite stuff */



_______________________________________________
tor-commits mailing list
tor-commits@xxxxxxxxxxxxxxxxxxxx
https://lists.torproject.org/cgi-bin/mailman/listinfo/tor-commits