From: Nilesh Trimbake Date: Tue, 6 Nov 2018 07:27:24 +0000 (+0530) Subject: Add valid pointer to image_util_decode_run() API X-Git-Tag: submit/tizen/20181106.165623^0 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=65dff2651e9184dce565bb47809e52b0a4cfc74f;p=profile%2Fwearable%2Fapps%2Fnative%2Fmessage.git Add valid pointer to image_util_decode_run() API This patch add valid pointer to image util api. Change-Id: I6d649e603301707557ba4d4ad7b3e2c4a72c15da --- diff --git a/src/Common/Utils/src/MediaUtils.cpp b/src/Common/Utils/src/MediaUtils.cpp index 5d868a6..d742563 100644 --- a/src/Common/Utils/src/MediaUtils.cpp +++ b/src/Common/Utils/src/MediaUtils.cpp @@ -228,6 +228,7 @@ long long downgradeImageQuality(const std::string &imagePath) unsigned int exifBuffLen = 0; unsigned char *jpegBuff = nullptr; unsigned long long int jpegBuffLen = 0; + unsigned long long int bufferSize = 0; std::ofstream outputFile; exifData = exif_data_new_from_file(imagePath.c_str()); @@ -256,7 +257,7 @@ long long downgradeImageQuality(const std::string &imagePath) return FileUtils::getFileSize(imagePath); } - res = image_util_decode_run(decode_h, &width, &height, nullptr); + res = image_util_decode_run(decode_h, &width, &height, &bufferSize); image_util_decode_destroy(decode_h); if (res != IMAGE_UTIL_ERROR_NONE) {