diff options
author | Alon Zakai <alonzakai@gmail.com> | 2013-09-18 16:33:54 -0500 |
---|---|---|
committer | Alon Zakai <alonzakai@gmail.com> | 2013-09-18 16:34:29 -0500 |
commit | fe524f9383fa6c06b7256f58fb1ef552b7660a7f (patch) | |
tree | 59e6927246b631c761113b20035fbc561dc0d32e /src/postamble.js | |
parent | fdf356f0c194e569aafcc3fe69c7e30dbb29c4ef (diff) |
handle memory initializer when there are deps added during preRun
Diffstat (limited to 'src/postamble.js')
-rw-r--r-- | src/postamble.js | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/postamble.js b/src/postamble.js index 8f585b86..cd892733 100644 --- a/src/postamble.js +++ b/src/postamble.js @@ -35,9 +35,10 @@ var preloadStartTime = null; var calledMain = false; var calledRun = false; -dependenciesFulfilled = function() { +dependenciesFulfilled = function runCaller() { // If run has never been called, and we should call run (INVOKE_RUN is true, and Module.noInitialRun is not false) if (!calledRun && shouldRunNow) run(); + if (!calledRun) dependenciesFulfilled = runCaller; // try this again later, after new deps are fulfilled } Module['callMain'] = Module.callMain = function callMain(args) { |