summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTobrun <tobrun.van.nuland@gmail.com>2018-03-01 11:04:32 +0100
committerTobrun <tobrun.van.nuland@gmail.com>2018-03-25 16:12:16 -0400
commitc74fc8634fec3cc38f6f42168139cdd85ce5e163 (patch)
treed2cdf2639885cd2a44297867ddcd582d0725dc58
parent690c7e58556335220791af156660a65af1fdebd6 (diff)
downloadqtlocation-mapboxgl-c74fc8634fec3cc38f6f42168139cdd85ce5e163.tar.gz
[android] - delete local ref pixel buffer when converting Image.java to core
-rw-r--r--platform/android/src/map/image.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/platform/android/src/map/image.cpp b/platform/android/src/map/image.cpp
index 52e0e0d255..c3b22b0054 100644
--- a/platform/android/src/map/image.cpp
+++ b/platform/android/src/map/image.cpp
@@ -29,7 +29,7 @@ mbgl::style::Image Image::getImage(jni::JNIEnv& env, jni::Object<Image> image) {
}
jni::GetArrayRegion(env, *pixels, 0, size, reinterpret_cast<jbyte*>(premultipliedImage.data.get()));
-
+ jni::DeleteLocalRef(env, pixels);
return mbgl::style::Image {name, std::move(premultipliedImage), pixelRatio};
}