aboutsummaryrefslogtreecommitdiff
path: root/src/postamble.js
diff options
context:
space:
mode:
Diffstat (limited to 'src/postamble.js')
-rw-r--r--src/postamble.js5
1 files changed, 3 insertions, 2 deletions
diff --git a/src/postamble.js b/src/postamble.js
index d6c059b8..90a86474 100644
--- a/src/postamble.js
+++ b/src/postamble.js
@@ -121,12 +121,13 @@ function run(args) {
if (Module['calledRun']) return; // run may have just been called through dependencies being fulfilled just in this very frame
function doRun() {
+ if (Module['calledRun']) return; // run may have just been called while the async setStatus time below was happening
+ Module['calledRun'] = true;
+
ensureInitRuntime();
preMain();
- assert(!Module['calledRun']);
- Module['calledRun'] = true;
if (Module['_main'] && shouldRunNow) {
Module['callMain'](args);
}