mirror of
https://github.com/RetroShare/RetroShare.git
synced 2025-05-03 14:45:12 -04:00
Fix global shutdown call from JSON API
This commit is contained in:
parent
5dbbe1ffd7
commit
8c9310f754
2 changed files with 9 additions and 3 deletions
|
@ -248,7 +248,13 @@ JsonApiServer::JsonApiServer(): configMutex("JsonApiServer config"),
|
|||
{
|
||||
INITIALIZE_API_CALL_JSON_CONTEXT;
|
||||
DEFAULT_API_CALL_JSON_RETURN(rb::OK);
|
||||
rsControl->rsGlobalShutDown();
|
||||
|
||||
/* Wrap inside RsThread::async because this call
|
||||
* RsThread::fullstop() also on JSON API server thread.
|
||||
* Calling RsThread::fullstop() from it's own thread should never
|
||||
* happen and if it happens an error message is printed
|
||||
* accordingly by RsThread::fullstop() */
|
||||
RsThread::async([](){ rsControl->rsGlobalShutDown(); });
|
||||
} );
|
||||
}, true);
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue