Skip to content
Merged
8 changes: 7 additions & 1 deletion app/src/app_android.cc
Original file line number Diff line number Diff line change
Expand Up @@ -311,7 +311,13 @@ static jobject GetPlatformAppByName(JNIEnv* jni_env, const char* name) {
name_string);
jni_env->DeleteLocalRef(name_string);
}
jni_env->ExceptionCheck();
if (jni_env->ExceptionCheck()) {
// Explicitly set `platform_app` to `NULL` if an exception was thrown
// because on KitKat (API 19) `CallStaticObjectMethod()` may return garbage
// instead of `NULL` if an exception was thrown, and callers of this
// function expect `NULL` to be returned if the app was not found.
platform_app = NULL; // NOLINT
}
jni_env->ExceptionClear();
return platform_app;
}
Expand Down
5 changes: 4 additions & 1 deletion release_build_files/readme.md
Original file line number Diff line number Diff line change
Expand Up @@ -378,7 +378,10 @@ code.
API.
- Remote Config(Android): Fix for getting Remote Config instance for a
specific app object.
([#991](https://github.com/firebase/quickstart-unity/issues/991).
([#991](https://github.com/firebase/quickstart-unity/issues/991)).
- General (Android): Fixed a potential SIGABRT when an app was created
with a non-default app name on Android KitKat
([#429](https://github.com/firebase/firebase-cpp-sdk/pull/429)).

### 7.3.0
- Changes
Expand Down