From 2e678b12312f306006b8e94377a05e976ac65562 Mon Sep 17 00:00:00 2001 From: "pengfei.zhou" Date: Tue, 2 Mar 2021 16:13:20 +0800 Subject: [PATCH] feat:when client is killded, kill debugging process --- doric-cli/src/server.ts | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/doric-cli/src/server.ts b/doric-cli/src/server.ts index 3d156884..5f94f0c3 100644 --- a/doric-cli/src/server.ts +++ b/doric-cli/src/server.ts @@ -53,7 +53,7 @@ export async function createServer() { } else if (resultObject.type === "C2D") { if (resultObject.cmd === "DEBUG_STOP") { client = undefined; - debugProcess?.kill(0); + debugProcess?.kill("SIGABRT"); } if (client === undefined) { client = ws; @@ -141,6 +141,7 @@ export async function createServer() { type: "S2D", cmd: "DEBUG_STOP" } as MSG)); + debugProcess?.kill("SIGABRT"); } }); ws.on('error', function (code: number) {