Skip to content

Commit

Permalink
write exceptions to stderr
Browse files Browse the repository at this point in the history
  • Loading branch information
milahu committed Apr 1, 2024
1 parent 4829507 commit 2aa1f72
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion app/src/converter.js
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,10 @@ function spawn(arg0, argv) {
}

for (let e of ["exit", "SIGINT", "SIGTERM", "uncaughtException"]) {
process.on(e, () => {
process.on(e, (...args) => {
if (e == "uncaughtException") {
console.error(args[0]);
}
for (let process of to_kill) {
try {
process.kill(9);
Expand Down

0 comments on commit 2aa1f72

Please sign in to comment.