Added forgotten lock in backtracer

This commit is contained in:
gabime 2019-08-27 02:28:49 +03:00
parent d1b97c0ba9
commit b155347560
1 changed files with 1 additions and 0 deletions

View File

@ -39,6 +39,7 @@ public:
// pop all items in the q and apply the give fun on each of them.
void foreach_pop(std::function<void(const details::log_msg)> fun)
{
std::lock_guard<std::mutex> lock{mutex_};
while (!messages_.empty())
{
log_msg_buffer popped;