diff options
author | max99x <max99x@gmail.com> | 2011-07-30 04:01:50 +0300 |
---|---|---|
committer | max99x <max99x@gmail.com> | 2011-07-30 04:01:50 +0300 |
commit | efacab6cd2ee666207ece72478c261dbaf476322 (patch) | |
tree | 3365a8bad36b49b3fe8999c9ece14946c4782e70 /src/preamble.js | |
parent | 2964998b4eb4d59e0b04931625a8ae34aa7d83d7 (diff) | |
parent | 0e64105b7e8463ef65a2004d3b0d47a1aa61d98d (diff) |
Merge branch 'master' of github.com:max99x/emscripten
Diffstat (limited to 'src/preamble.js')
-rw-r--r-- | src/preamble.js | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/preamble.js b/src/preamble.js index bf6628ae..21e9021e 100644 --- a/src/preamble.js +++ b/src/preamble.js @@ -483,7 +483,7 @@ function __shutdownRuntime__() { if (typeof func === 'number') { func = FUNCTION_TABLE[func]; } - func(atexit.arg); + func(atexit.arg === undefined ? null : atexit.arg); } // allow browser to GC, set heaps to null? @@ -553,7 +553,7 @@ function intArrayFromString(stringy, dontAddNull) { var chr = stringy.charCodeAt(i); if (chr > 0xFF) { #if ASSERTIONS - assert(false, 'String character code not inside 0 - 0xFF.'); + assert(false, 'Character code ' + chr + ' (' + stringy[i] + ') at offset ' + i + ' not in 0x00-0xFF.'); #endif chr &= 0xFF; } @@ -573,7 +573,7 @@ function intArrayToString(array) { var chr = array[i]; if (chr > 0xFF) { #if ASSERTIONS - assert(false, 'String character code not inside 0 - 0xFF.'); + assert(false, 'Character code ' + chr + ' (' + String.fromCharCode(chr) + ') at offset ' + i + ' not in 0x00-0xFF.'); #endif chr &= 0xFF; } |