aboutsummaryrefslogtreecommitdiff
path: root/src/or/control.c
diff options
context:
space:
mode:
authorNick Mathewson <nickm@torproject.org>2018-04-10 12:16:21 -0400
committerNick Mathewson <nickm@torproject.org>2018-04-10 12:16:21 -0400
commit16f08de0fd85b9fe8ace9f4905190fa6dc27e4ea (patch)
tree1f93ff4fcd5ab6f9e989cccb49f4c9c3c32aa62d /src/or/control.c
parent395fa0258d56b24e39cd714834ffe0dcb365ea25 (diff)
downloadtor-16f08de0fd85b9fe8ace9f4905190fa6dc27e4ea.tar.gz
tor-16f08de0fd85b9fe8ace9f4905190fa6dc27e4ea.zip
Remove TestingEnableTbEmptyEvent
This option was used for shadow testing previously, but is no longer used for anything. It interferes with refactoring our token buckets.
Diffstat (limited to 'src/or/control.c')
-rw-r--r--src/or/control.c23
1 files changed, 0 insertions, 23 deletions
diff --git a/src/or/control.c b/src/or/control.c
index 5a2fae64e7..0539ddaca3 100644
--- a/src/or/control.c
+++ b/src/or/control.c
@@ -1214,7 +1214,6 @@ static const struct control_event_t control_event_table[] = {
{ EVENT_CONF_CHANGED, "CONF_CHANGED"},
{ EVENT_CONN_BW, "CONN_BW" },
{ EVENT_CELL_STATS, "CELL_STATS" },
- { EVENT_TB_EMPTY, "TB_EMPTY" },
{ EVENT_CIRC_BANDWIDTH_USED, "CIRC_BW" },
{ EVENT_TRANSPORT_LAUNCHED, "TRANSPORT_LAUNCHED" },
{ EVENT_HS_DESC, "HS_DESC" },
@@ -6077,28 +6076,6 @@ control_event_circuit_cell_stats(void)
return 0;
}
-/** Tokens in <b>bucket</b> have been refilled: the read bucket was empty
- * for <b>read_empty_time</b> millis, the write bucket was empty for
- * <b>write_empty_time</b> millis, and buckets were last refilled
- * <b>milliseconds_elapsed</b> millis ago. Only emit TB_EMPTY event if
- * either read or write bucket have been empty before. */
-int
-control_event_tb_empty(const char *bucket, uint32_t read_empty_time,
- uint32_t write_empty_time,
- int milliseconds_elapsed)
-{
- if (get_options()->TestingEnableTbEmptyEvent &&
- EVENT_IS_INTERESTING(EVENT_TB_EMPTY) &&
- (read_empty_time > 0 || write_empty_time > 0)) {
- send_control_event(EVENT_TB_EMPTY,
- "650 TB_EMPTY %s READ=%d WRITTEN=%d "
- "LAST=%d\r\n",
- bucket, read_empty_time, write_empty_time,
- milliseconds_elapsed);
- }
- return 0;
-}
-
/* about 5 minutes worth. */
#define N_BW_EVENTS_TO_CACHE 300
/* Index into cached_bw_events to next write. */