mirror of
https://github.com/fish-shell/fish-shell
synced 2025-01-12 04:58:57 +00:00
Fix intermittent crash in iothread.cpp
The wrong lock was being taken around the result queue, leading to the occasional crash when processing interactive input. This didn't seem to really affect normal day-to-day usage, but it did sometimes cause the interactive tests to crash. Fixes #1692.
This commit is contained in:
parent
51c2005ea2
commit
761be8ab7f
1 changed files with 1 additions and 1 deletions
|
@ -332,7 +332,7 @@ static void iothread_service_result_queue()
|
|||
// Move the queue to a local variable
|
||||
std::queue<SpawnRequest_t *> result_queue;
|
||||
{
|
||||
scoped_lock queue_lock(s_main_thread_request_queue_lock);
|
||||
scoped_lock queue_lock(s_result_queue_lock);
|
||||
std::swap(result_queue, s_result_queue);
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue