diff options
author | Matthias P. Braendli <matthias.braendli@mpb.li> | 2018-04-20 12:29:24 +0200 |
---|---|---|
committer | Matthias P. Braendli <matthias.braendli@mpb.li> | 2018-04-20 12:29:24 +0200 |
commit | 411d03ac6b8ee1a8c06f952b9378c90516a715b7 (patch) | |
tree | 3236a6121eb9137a79b82699006df877e3876c32 /src/Log.h | |
parent | 4f9b087a578fac9dffef83cdcb41573468a4ae17 (diff) | |
download | dabmod-411d03ac6b8ee1a8c06f952b9378c90516a715b7.tar.gz dabmod-411d03ac6b8ee1a8c06f952b9378c90516a715b7.tar.bz2 dabmod-411d03ac6b8ee1a8c06f952b9378c90516a715b7.zip |
ThreadsafeQueue: add wakeup event instead of custom termination markers
This avoids the issue that the ~SDR termination marker doesn't reach the
consumer because it's still prebuffering
Diffstat (limited to 'src/Log.h')
-rw-r--r-- | src/Log.h | 5 |
1 files changed, 1 insertions, 4 deletions
@@ -138,10 +138,7 @@ class Logger { Logger(const Logger& other) = delete; const Logger& operator=(const Logger& other) = delete; ~Logger() { - // Special message to stop the thread - log_message_t m(trace, ""); - - m_message_queue.push(m); + m_message_queue.trigger_wakeup(); m_io_thread.join(); } |