Merge pull request #80686 from azuloo/lsp-thread-connection-error

Fixes LSP connection error when launched in a separate thread
This commit is contained in:
Rémi Verschelde 2023-08-21 19:26:43 +02:00
commit e43370d0fa
No known key found for this signature in database
GPG Key ID: C3336907360768E1

View File

@ -73,6 +73,7 @@ void GDScriptLanguageServer::_notification(int p_what) {
}
void GDScriptLanguageServer::thread_main(void *p_userdata) {
set_current_thread_safe_for_nodes(true);
GDScriptLanguageServer *self = static_cast<GDScriptLanguageServer *>(p_userdata);
while (self->thread_running) {
// Poll 20 times per second