[mw-devel] [Git][arthur/mw][master] js-duk: Set script_output=0 when js_exec'd code throws errors

Andrew Price welshbyte at sucs.org
Fri Aug 4 18:34:21 BST 2017


Andrew Price pushed to branch master at Justin Mitchell / mw


Commits:
f533e1f4 by Andrew Price at 2017-08-04T18:27:51+01:00
js-duk: Set script_output=0 when js_exec'd code throws errors

- - - - -


1 changed file:

- src/client/js-duk.c


Changes:

=====================================
src/client/js-duk.c
=====================================
--- a/src/client/js-duk.c
+++ b/src/client/js-duk.c
@@ -704,6 +704,7 @@ int js_exec(char *name, int argc, const char **argv)
 		} else {
 			fprintf(stderr, "mwjs error: %s\n", duk_safe_to_string(ctx, -1));
 		}
+		script_output = 0;
 	} else if (duk_is_boolean(ctx, -1) && !duk_get_boolean(ctx, -1)) {
 		script_output = 0;
 	}



View it on GitLab: https://projects.sucs.org/arthur/mw/commit/f533e1f49ce120ea27ae7c5320ba9a0e13fbe7d2

---
View it on GitLab: https://projects.sucs.org/arthur/mw/commit/f533e1f49ce120ea27ae7c5320ba9a0e13fbe7d2
You're receiving this email because of your account on projects.sucs.org.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.sucs.org/pipermail/mw-devel/attachments/20170804/3a207602/attachment.html>


More information about the mw-devel mailing list