fixup! refactor: tr_web (#2633) (#2693)

race condition in TR_ASSERT
This commit is contained in:
Charles Kerr 2022-02-23 11:00:40 -06:00 committed by GitHub
parent 7238724318
commit a0c25b21af
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 3 additions and 2 deletions

View File

@ -132,6 +132,7 @@ public:
this->user_agent = *ua;
}
auto const lock = std::unique_lock(queued_tasks_mutex);
curl_thread = std::make_unique<std::thread>(curlThreadFunc, this);
}
@ -445,9 +446,9 @@ private:
curl_multi_add_handle(multi.get(), task->easy());
}
impl->queued_tasks.clear();
}
impl->resumePausedTasks();
impl->resumePausedTasks();
}
// Adapted from https://curl.se/libcurl/c/curl_multi_wait.html docs.
// 'numfds' being zero means either a timeout or no file descriptors to