summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorAlex Blasche <alexander.blasche@qt.io>2019-08-06 09:28:46 +0200
committerAlex Blasche <alexander.blasche@qt.io>2019-08-07 13:06:23 +0200
commit406b18fdb3704a9e9e66cefbc74e7cff55f1947c (patch)
tree75a0d62ab25cf3aad8fc568d449ddb38d227d1f1 /src
parentc9d585da2ddd49108d7b56f480bcfc9d71b67dbf (diff)
downloadqtconnectivity-406b18fdb3704a9e9e66cefbc74e7cff55f1947c.tar.gz
Fix QLEAdvertisingData::setManufacturerData on Android
The manufacturer data was not properly set because the related Java function requires a byte[] as second parameter. The equivelent JNI type is [B and not [B]. This caused a crash of the application. Change-Id: Iaa062ed9eb01e03d155583519d3f6a6bc01d72f7 Reviewed-by: Timur Pocheptsov <timur.pocheptsov@qt.io>
Diffstat (limited to 'src')
-rw-r--r--src/bluetooth/qlowenergycontroller_android.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/bluetooth/qlowenergycontroller_android.cpp b/src/bluetooth/qlowenergycontroller_android.cpp
index 35d943fc..86e6ade7 100644
--- a/src/bluetooth/qlowenergycontroller_android.cpp
+++ b/src/bluetooth/qlowenergycontroller_android.cpp
@@ -940,7 +940,7 @@ static QAndroidJniObject createJavaAdvertiseData(const QLowEnergyAdvertisingData
env->SetByteArrayRegion(nativeData, 0, nativeSize,
reinterpret_cast<const jbyte*>(data.manufacturerData().constData()));
builder = builder.callObjectMethod("addManufacturerData",
- "(I[B])Landroid/bluetooth/le/AdvertiseData$Builder;",
+ "(I[B)Landroid/bluetooth/le/AdvertiseData$Builder;",
data.manufacturerId(), nativeData);
env->DeleteLocalRef(nativeData);