Skip to content

Commit 28c4f28

Browse files
committed
improvements to shutdown code
1 parent 27c2d85 commit 28c4f28

File tree

3 files changed

+2
-7
lines changed

3 files changed

+2
-7
lines changed

apps/elixir_ls_debugger/lib/debugger.ex

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -22,12 +22,6 @@ defmodule ElixirLS.Debugger do
2222

2323
@impl Application
2424
def stop(_state) do
25-
if ElixirLS.Utils.WireProtocol.io_intercepted?() do
26-
Output.debugger_important("ElixirLS debugger has crashed")
27-
28-
System.stop(1)
29-
end
30-
3125
:ok
3226
end
3327
end

apps/elixir_ls_debugger/lib/debugger/server.ex

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -202,6 +202,7 @@ defmodule ElixirLS.Debugger.Server do
202202
def terminate(reason, _state = %__MODULE__{}) do
203203
if reason != :normal do
204204
Output.debugger_important("Terminating: #{Exception.format_exit(reason)}")
205+
System.stop(1)
205206
end
206207
end
207208

apps/language_server/lib/language_server.ex

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@ defmodule ElixirLS.LanguageServer do
3535
"ElixirLS has crashed. See Output panel."
3636
)
3737

38-
System.stop(1)
38+
System.halt(1)
3939
end
4040

4141
:ok

0 commit comments

Comments
 (0)