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

Commit 1987cbf4 authored by Himanshu Rawat's avatar Himanshu Rawat Committed by Automerger Merge Worker
Browse files

Merge "Log the reason when bonding fails to initiate" am: 7bfd79ae

parents 723c3482 7bfd79ae
Loading
Loading
Loading
Loading
+5 −0
Original line number Diff line number Diff line
@@ -1137,6 +1137,11 @@ static jboolean createBondNative(JNIEnv* env, jobject obj, jbyteArray address,
  } else {
    ret = sBluetoothInterface->create_bond((RawAddress*)addr, transport);
  }

  if (ret != BT_STATUS_SUCCESS) {
    ALOGW("%s: Failed to initiate bonding. Status = %d", __func__, ret);
  }

  env->ReleaseByteArrayElements(address, addr, 0);
  return (ret == BT_STATUS_SUCCESS) ? JNI_TRUE : JNI_FALSE;
}