Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Menu
Open sidebar
NetBeans
Apache NetBeans
Commits
d2b8034b
Commit
d2b8034b
authored
Nov 10, 2020
by
Svata Dedic
Committed by
Laszlo Kishalmi
Nov 12, 2020
Browse files
Prevent endless restarts when changing JDKs.
parent
f556f4b8
Changes
1
Hide whitespace changes
Inline
Side-by-side
java/java.lsp.server/vscode/src/extension.ts
View file @
d2b8034b
...
...
@@ -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
;
}
}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment