- 16 Aug, 2020 1 commit
-
-
Rob Swindell authored
-
- 29 Mar, 2020 4 commits
-
-
rswindell authored
specially, just pass them on to the script as-is. Included a JSDOC note about the use of js.exec.apply() to pass a variable number of arguments (ala execv). Thanks Tracker1 for the pointer to 'spread' which led me to function.apply() and the JS-standard method of achieving the result I needed with this enhancement. I still think that a script that calls exit() is unlikely to expect non-string arguments in the first place, but if we don't need special case behavior, it's better not to add it and keep the behavior consistent with load() and require(). That was the decision of the executive board anyway. :-|
-
rswindell authored
script are arrays, pass each element of the array as a separate argument to the child script. This allows one script to generate a variable-length list of arguments to be passed to another.
-
rswindell authored
Improve "script missing" error reporting in js.exec().
-
rswindell authored
not v3.16.
-
- 29 Aug, 2019 1 commit
-
-
deuce authored
-
- 28 Aug, 2019 1 commit
-
-
rswindell authored
-
- 27 Aug, 2019 2 commits
-
-
deuce authored
child scope.
-
deuce authored
A child of the parent scopes js object can't do on_exit() stuff properly due to the missing private context. Create a new JS object in the child instead. We also need to copy in the js.load_path_list array contents since we don't want the child changing the parent by accident.
-
- 26 Aug, 2019 1 commit
-
-
deuce authored
exit_code, and don't throw the exception in the caller. Remove support for js_scope == scope. It sorta defeats the whole purpose of js.exec().
-
- 25 Aug, 2019 2 commits
-
-
rswindell authored
-
deuce authored
This allows executing a new script in a specified scope, much like load(). There are important differences however... 1) js.exec() *must* specify a scope. 2) js.exec()d scripts can call exit() and their handlers are ran then, rather than when the parent script exists as in js.load(). 3) The js object is installed in the scope with the real JS object as the prototype. This generally shouldn't be an issue, but if you're doing strange things, stranger things may happen. 4) As part of #3, the exec_path/exec_dir/exec_file/startup_dir/scope properties of the JS object represent the new script, not the calling one. 5) js.exec() only searches in the passed startup dir (if specified) and the current js.exec_dir path. It does not search the load paths or the mods directory at all. This API is also subject to change.
-
- 28 Dec, 2018 1 commit
-
-
rswindell authored
-
- 20 Feb, 2018 2 commits
-
-
rswindell authored
-
rswindell authored
HANDLE_PENDING() contains a return, so it's theoretically possible that the memory allocated by the previous JSVALUE/STRING_TO_... allocation could be leaked. So now we pass an optional pointer to HANDLE_PENDING() which will call free() on it if it's not NULL, and then sets it to NULL for good measure.
-
- 26 Sep, 2015 1 commit
-
-
deuce authored
When checking the terminated value, check all parents until you either find one that is TRUE, or run out of parents. Do *not* go up the chain of parents when *setting* terminated. Background threads still can't set it (TODO?).
-
- 25 Apr, 2015 2 commits
-
-
deuce authored
-
deuce authored
scripts global scope (as opposed to js.global which is the instance global scope), and having exit() define exit_code in js.scope instead of js.global. This also sets exit_code in js.scope to null when preparing to execute a new script. If a new script starts in the same scope as an old one, the old exit_code value will be destroyed. This should only impact scripts where js.global != js.scope (bbs.exec()ed, and mailsrvr)
-
- 08 Oct, 2013 1 commit
-
-
deuce authored
-
- 03 Oct, 2013 1 commit
-
-
rswindell authored
that MSVC RTL functions will not terminate the program (e.g. jsexec, sbbsctrl) if an invalid parameter is detected (e.g. unsupported format specifier in call to strftime()).
-
- 13 Sep, 2013 1 commit
-
-
rswindell authored
counter/limits as branch counter/limits.
-
- 16 Mar, 2013 1 commit
-
-
rswindell authored
slightly improved JSDOC descriptions. Updated JSDOC description of the 'js' object to be more general.
-
- 08 Feb, 2013 1 commit
-
-
deuce authored
-
- 15 Mar, 2012 4 commits
-
-
deuce authored
-
deuce authored
back into the container because str_list_t's tend to realloc()
-
deuce authored
-
deuce authored
global object exits. This fixes a problem where the terminal server reuses the same global object for all JS scripts, and they uses nested exec()s. When the innermost script would exit, the on_exit evals would occure in IT'S scope rather than in the scope it was defined in, resulting in incorrect behaviour.
-
- 12 Nov, 2011 1 commit
-
-
deuce authored
-
- 02 Nov, 2011 1 commit
-
-
deuce authored
is to periodically call JS_YieldRequest from an operation callback."
-
- 29 Oct, 2011 1 commit
-
-
deuce authored
resolve callbacks.
-
- 28 Oct, 2011 1 commit
-
-
rswindell authored
has its own functional "too much recursion" detection. Replaced "branch callback" stuff with "operational callback". JavaScriptBranchLimit has been replaced with JavaScriptTimeLimit (default value: 24 hours)
-
- 26 Oct, 2011 1 commit
-
-
deuce authored
functions when an excpetion is pending. Some work still needs to be done on js_msgbase.c, js_user.c, and mailsrvr.c
-
- 19 Oct, 2011 1 commit
-
-
deuce authored
-
- 16 Oct, 2011 2 commits
- 11 Oct, 2011 1 commit
-
-
deuce authored
-
- 10 Oct, 2011 1 commit
-
-
deuce authored
Only js_ValueToStringBytes() still leaks.
-
- 09 Oct, 2011 3 commits