diff --git a/Objective-J/CommonJS/lib/objective-j.js b/Objective-J/CommonJS/lib/objective-j.js index 4b74070c2..883e34e7f 100644 --- a/Objective-J/CommonJS/lib/objective-j.js +++ b/Objective-J/CommonJS/lib/objective-j.js @@ -119,7 +119,10 @@ exports.run = function(args) } if (typeof main === "function") + { main([arg0].concat(argv)); + endCommand = true; + } require("browser/timeout").serviceTimeouts(); diff --git a/Objective-J/CommonJS/objj-executable b/Objective-J/CommonJS/objj-executable index 919302c11..9f2f05a02 100755 --- a/Objective-J/CommonJS/objj-executable +++ b/Objective-J/CommonJS/objj-executable @@ -3,5 +3,5 @@ var execPath = require("file").path(module.path); var mainPath = execPath.dirname().dirname().join("lib", execPath.basename(), "main.j"); -var args = ["objj", String(mainPath)].concat(system.args.slice(1)); +var args = ["objj", String(mainPath), "--"].concat(system.args.slice(1)); require("objective-j").run(args);