mirror of
https://gitlab.torproject.org/tpo/core/tor.git
synced 2024-11-10 21:23:58 +01:00
incomplete patch for matt's info controller signal term bug
svn:r4728
This commit is contained in:
parent
bfe65db284
commit
5c4da9dec6
@ -253,6 +253,10 @@ connection_free(connection_t *conn)
|
||||
if (conn->state == OR_CONN_STATE_OPEN)
|
||||
directory_set_dirty();
|
||||
}
|
||||
if (conn->type == CONN_TYPE_CONTROL) {
|
||||
conn->event_mask = 0;
|
||||
control_update_global_event_mask();
|
||||
}
|
||||
connection_unregister(conn);
|
||||
_connection_free(conn);
|
||||
}
|
||||
|
@ -127,7 +127,6 @@ static char authentication_cookie[AUTHENTICATION_COOKIE_LEN];
|
||||
|
||||
static void connection_printf_to_buf(connection_t *conn, const char *format, ...)
|
||||
CHECK_PRINTF(2,3);
|
||||
static void update_global_event_mask(void);
|
||||
static void send_control0_message(connection_t *conn, uint16_t type,
|
||||
uint32_t len, const char *body);
|
||||
static void send_control_done(connection_t *conn);
|
||||
@ -204,8 +203,8 @@ log_severity_to_event(int severity)
|
||||
|
||||
/** Set <b>global_event_mask</b> to the bitwise OR of each live control
|
||||
* connection's event_mask field. */
|
||||
static void
|
||||
update_global_event_mask(void)
|
||||
void
|
||||
control_update_global_event_mask(void)
|
||||
{
|
||||
connection_t **conns;
|
||||
int n_conns, i;
|
||||
@ -847,7 +846,7 @@ handle_control_setevents(connection_t *conn, uint32_t len, const char *body)
|
||||
}
|
||||
conn->event_mask = event_mask;
|
||||
|
||||
update_global_event_mask();
|
||||
control_update_global_event_mask();
|
||||
send_control_done(conn);
|
||||
return 0;
|
||||
}
|
||||
|
@ -1536,6 +1536,7 @@ typedef enum or_conn_status_event_t {
|
||||
OR_CONN_EVENT_CLOSED = 3,
|
||||
} or_conn_status_event_t;
|
||||
|
||||
void control_update_global_event_mask(void);
|
||||
void control_adjust_event_log_severity(void);
|
||||
void disable_control_logging(void);
|
||||
void enable_control_logging(void);
|
||||
|
Loading…
Reference in New Issue
Block a user