aboutsummaryrefslogtreecommitdiff
path: root/src/preamble.js
diff options
context:
space:
mode:
authorAlon Zakai <alonzakai@gmail.com>2011-04-24 19:44:02 -0700
committerAlon Zakai <alonzakai@gmail.com>2011-04-24 19:44:02 -0700
commit9f0ba583d6ed8ed830cc2871d91d3339d36d36d7 (patch)
tree5b5c701db7fde57fc205e6f4106ea987b624ff8d /src/preamble.js
parent2fb5e321d9c1ed6701cfc6689bcf78eb6c22e41f (diff)
support for __cxa_atexit argument
Diffstat (limited to 'src/preamble.js')
-rw-r--r--src/preamble.js5
1 files changed, 3 insertions, 2 deletions
diff --git a/src/preamble.js b/src/preamble.js
index 0232ff20..44f5c876 100644
--- a/src/preamble.js
+++ b/src/preamble.js
@@ -287,11 +287,12 @@ function __initializeRuntime__() {
function __shutdownRuntime__() {
while( __ATEXIT__.length > 0) {
- var func = __ATEXIT__.pop();
+ var atexit = __ATEXIT__.pop();
+ var func = atexit.func;
if (typeof func === 'number') {
func = FUNCTION_TABLE[func];
}
- func();
+ func(atexit.arg);
}
}