feat:when client is killded, kill debugging process

This commit is contained in:
pengfei.zhou 2021-03-02 16:13:20 +08:00 committed by osborn
parent 88dc9c9334
commit 2e678b1231

View File

@ -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) {