diff --git a/mobile/android/base/GeckoAppShell.java b/mobile/android/base/GeckoAppShell.java index 57afd313afc..462b2536df5 100644 --- a/mobile/android/base/GeckoAppShell.java +++ b/mobile/android/base/GeckoAppShell.java @@ -2146,7 +2146,7 @@ public class GeckoAppShell public static void pumpMessageLoop() { // We're going to run the Looper below, but we need a way to break out, so - // we post this Runnable that throws a RuntimeException. This causes the loop + // we post this Runnable that throws an AssertionError. This causes the loop // to exit without marking the Looper as dead. The Runnable is added to the // end of the queue, so it will be executed after anything // else that has been added prior. @@ -2157,13 +2157,13 @@ public class GeckoAppShell // here we are. sGeckoHandler.post(new Runnable() { public void run() { - throw new RuntimeException(); + throw new AssertionError(); } }); try { Looper.loop(); - } catch(Exception ex) {} + } catch(Throwable ex) {} } static class AsyncResultHandler extends GeckoApp.FilePickerResultHandler {