Skip to content

Commit 64df777

Browse files
committed
Listen for close event rather than exit
Listening to the exit event leads to occasional data loss. See nateps/connect-gzip#18
1 parent 89c83f7 commit 64df777

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

lib/runner.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -59,7 +59,7 @@ exports.compile = function(input, options, callback) {
5959
compiler.stderr.on('data', function(data) {
6060
return stderr += data;
6161
});
62-
compiler.on('exit', function(code) {
62+
compiler.on('close', function(code) {
6363
var error;
6464
if (code !== 0) {
6565
error = new Error(stderr);

0 commit comments

Comments
 (0)