mirror of
https://github.com/MaskRay/ccls.git
synced 2024-11-26 17:41:58 +00:00
Delete previous QueueManager instance if creating multiple.
This commit is contained in:
parent
5d4e0a5020
commit
a9a905b0d2
@ -51,6 +51,8 @@ QueueManager* QueueManager::instance() {
|
|||||||
void QueueManager::CreateInstance(MultiQueueWaiter* querydb_waiter,
|
void QueueManager::CreateInstance(MultiQueueWaiter* querydb_waiter,
|
||||||
MultiQueueWaiter* indexer_waiter,
|
MultiQueueWaiter* indexer_waiter,
|
||||||
MultiQueueWaiter* stdout_waiter) {
|
MultiQueueWaiter* stdout_waiter) {
|
||||||
|
if (instance_)
|
||||||
|
delete instance_;
|
||||||
instance_ = new QueueManager(querydb_waiter, indexer_waiter, stdout_waiter);
|
instance_ = new QueueManager(querydb_waiter, indexer_waiter, stdout_waiter);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user