Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 469eadc9 authored by Jack He's avatar Jack He Committed by android-build-merger
Browse files

Merge "JNI: Check if service name is null in createSocketChannelNative"

am: 7e2dd73d

Change-Id: I07e0c67f1d836af587c89aa1f364fb1739b523e0
parents bfb07a63 7e2dd73d
Loading
Loading
Loading
Loading
+3 −1
Original line number Diff line number Diff line
@@ -1255,7 +1255,9 @@ static jint createSocketChannelNative(JNIEnv* env, jobject obj, jint type,
    goto done;
  }
  uuidBytes = env->GetByteArrayElements(uuid, nullptr);
  if (serviceName != nullptr) {
    nativeServiceName = env->GetStringUTFChars(serviceName, nullptr);
  }
  if (uuidBytes == nullptr) {
    jniThrowIOException(env, EINVAL);
    goto done;