Bug 1351170 - Don't crash on selection exception in Beta; r=me
authorJim Chen <nchen@mozilla.com>
Tue, 25 Jul 2017 15:32:53 -0400
changeset 422091 7d134c8d7cc602cf726dab77bb211d81c65d381b
parent 422090 db7e15eb0f1c14d8c004d67e14f7a65ef651738a
child 422092 ae7f1e8f2b350dc6b808d79b32d4dc13b17fc6a9
push id1517
push userjlorenzo@mozilla.com
push dateThu, 14 Sep 2017 16:50:54 +0000
treeherdermozilla-release@3b41fd564418 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersme
bugs1351170
milestone56.0a1
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
Bug 1351170 - Don't crash on selection exception in Beta; r=me Don't crash when we encounter a selection exception when in Beta. Still crash when in Nightly so we can investigate the source of the crash. r=me for trivial patch. MozReview-Commit-ID: HgmudX4VfWO
widget/android/GeckoEditableSupport.cpp
--- a/widget/android/GeckoEditableSupport.cpp
+++ b/widget/android/GeckoEditableSupport.cpp
@@ -659,17 +659,21 @@ GeckoEditableSupport::FlushIMEChanges(Fl
         if (aFlags != FLUSH_FLAG_RECOVER) {
             // First time seeing an exception; try flushing text.
             env->ExceptionClear();
             __android_log_print(ANDROID_LOG_WARN, "GeckoEditableSupport",
                     "Recovering from IME exception");
             FlushIMEText(FLUSH_FLAG_RECOVER);
         } else {
             // Give up because we've already tried.
+#ifdef RELEASE_OR_BETA
+            env->ExceptionClear();
+#else
             MOZ_CATCH_JNI_EXCEPTION(env);
+#endif
         }
         return true;
     };
 
     // Commit the text change and selection change transaction.
     mIMETextChanges.Clear();
 
     for (const TextRecord& record : textTransaction) {