Browse Source

Exit the process on module load error. (temporary)

v0.7.4-release
Ryan 16 years ago
parent
commit
0407145c11
  1. 2
      src/node.js

2
src/node.js

@ -111,6 +111,7 @@ node.Module.prototype.loadObject = function (callback) {
} else {
node.stdio.writeError("Error reading " + self.filename + "\n");
loadPromise.emitError();
node.exit(1);
}
});
return loadPromise;
@ -131,6 +132,7 @@ node.Module.prototype.loadScript = function (callback) {
cat_promise.addErrback(function () {
node.stdio.writeError("Error reading " + self.filename + "\n");
loadPromise.emitError();
node.exit(1);
});
cat_promise.addCallback(function (content) {

Loading…
Cancel
Save