LanguageClient: prevent sending symbol request to unreachable server

Change-Id: Ie7b7ee2a89b3e7e7d55b2ef1714b574c87a2897e
Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
This commit is contained in:
David Schulz
2021-07-01 08:00:51 +02:00
parent 79ca424782
commit 8ff74cc46c

View File

@@ -62,6 +62,10 @@ void DocumentSymbolCache::requestSymbols(const DocumentUri &uri)
void DocumentSymbolCache::requestSymbolsImpl()
{
if (!m_client->reachable()) {
m_compressionTimer.start(200);
return;
}
for (const DocumentUri &uri : qAsConst(m_compressedUris)) {
auto entry = m_cache.find(uri);
if (entry != m_cache.end()) {