瀏覽代碼

chore(subprocess): document disconnect recheck

pku-xht 1 月之前
父節點
當前提交
ef0815db7f
共有 1 個文件被更改,包括 1 次插入 和 0 次删除
  1. 1 0
      packages/subprocess/subprocess-local/src/windows-job.ts

+ 1 - 0
packages/subprocess/subprocess-local/src/windows-job.ts

@@ -78,6 +78,7 @@ class WindowsJobOwner implements BoundProcessOwner {
         if (error !== null && this.runner.connected) this.runner.kill()
         if (error !== null && this.runner.connected) this.runner.kill()
       })
       })
     } catch {
     } catch {
+      // oxlint-disable-next-line typescript/no-unnecessary-condition -- ChildProcess.send() may synchronously disconnect before throwing.
       if (this.runner.connected) this.runner.kill()
       if (this.runner.connected) this.runner.kill()
     }
     }
   }
   }