Skip to content

Commit

Permalink
don't try restarting dcd after shutdownRequest, shutdown on exit
Browse files Browse the repository at this point in the history
  • Loading branch information
WebFreak001 committed Apr 3, 2018
1 parent 9584d80 commit 5be8531
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 0 deletions.
2 changes: 2 additions & 0 deletions source/app.d
Original file line number Diff line number Diff line change
Expand Up @@ -106,6 +106,8 @@ void processNotify(RequestMessage msg)
if (msg.method == "exit" || served.extension.shutdownRequested)
{
rpc.stop();
if (!served.extension.shutdownRequested)
served.extension.shutdown();
return;
}
if (msg.method == "workspace/didChangeConfiguration")
Expand Down
2 changes: 2 additions & 0 deletions source/served/extension.d
Original file line number Diff line number Diff line change
Expand Up @@ -245,6 +245,8 @@ void handleBroadcast(JSONValue data)

void startDCD()
{
if (shutdownRequested)
return;
hasDCD = safe!(dcd.start)(workspaceRoot, config.d.dcdClientPath,
config.d.dcdServerPath, cast(ushort) 9166, false);
if (hasDCD)
Expand Down

0 comments on commit 5be8531

Please sign in to comment.