aboutsummaryrefslogtreecommitdiff
path: root/computer-network-experiment/Output.h
diff options
context:
space:
mode:
authorcrupest <crupest@outlook.com>2021-06-07 14:05:51 +0800
committercrupest <crupest@outlook.com>2021-06-07 14:05:51 +0800
commit6774bcc32ac23728827b36a8c2c2350e811f7940 (patch)
treeee55e8f7ca3ef7c937dd797f863016dfb740e21b /computer-network-experiment/Output.h
parent7f2badbf713d37a75df03c1e0704ddab6af06627 (diff)
downloadlife-6774bcc32ac23728827b36a8c2c2350e811f7940.tar.gz
life-6774bcc32ac23728827b36a8c2c2350e811f7940.tar.bz2
life-6774bcc32ac23728827b36a8c2c2350e811f7940.zip
...
Diffstat (limited to 'computer-network-experiment/Output.h')
-rw-r--r--computer-network-experiment/Output.h6
1 files changed, 6 insertions, 0 deletions
diff --git a/computer-network-experiment/Output.h b/computer-network-experiment/Output.h
index b81dbfd..22b913a 100644
--- a/computer-network-experiment/Output.h
+++ b/computer-network-experiment/Output.h
@@ -5,7 +5,9 @@
#include <fmt/format.h>
#include <folly/MPMCPipeline.h>
#include <folly/MPMCQueue.h>
+#include <folly/CancellationToken.h>
+#include <thread>
#include <iostream>
enum class OutputType { Normal, Error };
@@ -42,3 +44,7 @@ void SendOutput(OutputType type, StringView format, Args &&...args) {
}
void OutputThread();
+
+void SignalAndWaitForOutputThreadStop();
+
+extern std::thread output_thread;