Catch leaked exceptions in superspawn and convert them to rejections
authorRaphael von der Grün <raphinesse@gmail.com>
Mon, 1 Apr 2019 14:47:27 +0000 (16:47 +0200)
committerGitHub <noreply@github.com>
Mon, 1 Apr 2019 14:47:27 +0000 (16:47 +0200)
commit469e7b4a49a1a39c7fc22aa206730b9d58613467
treead35dbc5507c13a5a7b8a10c367ad60c2491450f
parent3c72aec70827185253c12f81e9837e73e03e5f1b
Catch leaked exceptions in superspawn and convert them to rejections

At least until Node.js 8, child_process.spawn will throw exceptions
instead of emitting error events in certain cases (like EACCES), Thus we
have to wrap the execution in try/catch to convert them into rejections.
spec/superspawn.spec.js
src/superspawn.js