Skip to content
This repository was archived by the owner on Feb 25, 2025. It is now read-only.

Commit 9ba6e3e

Browse files
Check whether the lookup of android.hardware.HardwareBuffer found a class (#44304)
1 parent c83533f commit 9ba6e3e

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

shell/platform/android/platform_view_android_jni_impl.cc

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1211,7 +1211,7 @@ bool PlatformViewAndroid::Register(JNIEnv* env) {
12111211
g_hardware_buffer_class = new fml::jni::ScopedJavaGlobalRef<jclass>(
12121212
env, env->FindClass("android/hardware/HardwareBuffer"));
12131213

1214-
if (g_hardware_buffer_class != nullptr) {
1214+
if (!g_hardware_buffer_class->is_null()) {
12151215
g_hardware_buffer_close_method =
12161216
env->GetMethodID(g_hardware_buffer_class->obj(), "close", "()V");
12171217
} else {

0 commit comments

Comments
 (0)