summaryrefslogtreecommitdiff
path: root/src/common/torlog.h
diff options
context:
space:
mode:
authorNick Mathewson <nickm@torproject.org>2018-05-01 10:05:22 -0400
committerNick Mathewson <nickm@torproject.org>2018-05-01 10:18:49 -0400
commitb0224bf7282f2ec968a46e35a2a8dab1ddaf0667 (patch)
tree646f76e0426b08e660cb03609717fc7a552bcd37 /src/common/torlog.h
parent4cf6b67f5e83e1a26b4b2fbdb3b169c137a30687 (diff)
downloadtor-b0224bf7282f2ec968a46e35a2a8dab1ddaf0667.tar.gz
tor-b0224bf7282f2ec968a46e35a2a8dab1ddaf0667.zip
Add a mechanism for the logging system to report queued callbacks
Sometimes the logging system will queue a log message for later. When it does this, the callback will either get flushed at the next safe time, or from the second-elapsed callback. But we're trying to eliminate the second-elapsed callback, so let's make a way for the log system to tell its users about this.
Diffstat (limited to 'src/common/torlog.h')
-rw-r--r--src/common/torlog.h2
1 files changed, 2 insertions, 0 deletions
diff --git a/src/common/torlog.h b/src/common/torlog.h
index ac632ff521..de389883c0 100644
--- a/src/common/torlog.h
+++ b/src/common/torlog.h
@@ -154,6 +154,8 @@ int add_android_log(const log_severity_list_t *severity,
const char *android_identity_tag);
#endif // HAVE_ANDROID_LOG_H.
int add_callback_log(const log_severity_list_t *severity, log_callback cb);
+typedef void (*pending_callback_callback)(void);
+void logs_set_pending_callback_callback(pending_callback_callback cb);
void logs_set_domain_logging(int enabled);
int get_min_log_level(void);
void switch_logs_debug(void);