ecode: Gracefully shutdown LSP servers.

This commit is contained in:
Martín Lucas Golini
2023-04-04 14:06:25 -03:00
parent 91822ef6a5
commit ad44071880
3 changed files with 16 additions and 1 deletions

View File

@@ -43,7 +43,7 @@ bool PluginManager::setEnabled( const std::string& id, bool enable, bool sync )
return true;
}
if ( !enable && plugin != nullptr ) {
eeSAFE_DELETE( plugin );
mThreadPool->run( [plugin]() { eeDelete( plugin ); } );
{
Lock l( mSubscribedPluginsMutex );
mSubscribedPlugins.erase( id );