Commit d2b8034b authored by Svata Dedic's avatar Svata Dedic Committed by Laszlo Kishalmi
Browse files

Prevent endless restarts when changing JDKs.

parent f556f4b8
......@@ -251,7 +251,9 @@ function doActivateWithJDK(specifiedJDK: string | null, context: ExtensionContex
let ideRunning = new Promise((resolve, reject) => {
let collectedText : string | null = '';
function logAndWaitForEnabled(text: string) {
activationPending = false;
if (p == nbProcess) {
activationPending = false;
}
log.append(text);
if (collectedText == null) {
return;
......@@ -357,7 +359,9 @@ function doActivateWithJDK(specifiedJDK: string | null, context: ExtensionContex
},
closed : function(): CloseAction {
log.appendLine("Connection to Apache NetBeans Language Server closed.");
restartWithJDKLater(10000, false);
if (!activationPending) {
restartWithJDKLater(10000, false);
}
return CloseAction.DoNotRestart;
}
}
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment