Browse Source

Allow node.js to exit naturally

Calling `process.exit()` can cause process to abort before the entire text
is written to the stdout.

When I tested this, out of 1.8Mb binary only 65536 bytes had been written.
pull/204/merge
Alex Kocharin 8 years ago
parent
commit
1845175502
  1. 2
      bin/markdown-it.js

2
bin/markdown-it.js

@ -100,6 +100,4 @@ readFile(options.file, 'utf8', function (err, input) {
}
process.stdout.write(output);
process.exit(0);
});

Loading…
Cancel
Save