aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAlon Zakai <alonzakai@gmail.com>2013-03-20 16:18:19 -0700
committerAlon Zakai <alonzakai@gmail.com>2013-03-20 16:18:19 -0700
commite7684016a014cd17ea9525bf8ba8909464e052eb (patch)
tree100be7ef27b0e384e7e4293585a35ee324e5846d
parent22e4c333a7b17ba2e909b9118ef5fb6e4d0f5221 (diff)
do not show the simulate-infinite-loop exception
-rw-r--r--src/library_browser.js2
-rw-r--r--src/library_glut.js2
-rw-r--r--src/postamble.js2
3 files changed, 3 insertions, 3 deletions
diff --git a/src/library_browser.js b/src/library_browser.js
index e61f84b5..b1e4190b 100644
--- a/src/library_browser.js
+++ b/src/library_browser.js
@@ -637,7 +637,7 @@ mergeInto(LibraryManager.library, {
Browser.mainLoop.scheduler();
if (simulateInfiniteLoop) {
- throw 'emscripten_set_main_loop simulating infinite loop by throwing so we get right into the JS event loop';
+ throw 'SimulateInfiniteLoop';
}
},
diff --git a/src/library_glut.js b/src/library_glut.js
index bb4dfefa..49380367 100644
--- a/src/library_glut.js
+++ b/src/library_glut.js
@@ -433,7 +433,7 @@ var LibraryGLUT = {
glutMainLoop: function() {
_glutReshapeWindow(Module['canvas'].width, Module['canvas'].height);
_glutPostRedisplay();
- throw 'GLUT mainloop called, simulating infinite loop by throwing so we get right into the JS event loop';
+ throw 'SimulateInfiniteLoop';
},
};
diff --git a/src/postamble.js b/src/postamble.js
index 9ee93673..561ee826 100644
--- a/src/postamble.js
+++ b/src/postamble.js
@@ -30,7 +30,7 @@ Module.callMain = function callMain(args) {
catch(e) {
if (e.name == 'ExitStatus') {
return e.status;
- } else {
+ } else if (e !== 'SimulateInfiniteLoop') {
throw e;
}
} finally {