IVGCVSW-5943 Updates for latest Android
* Use the correct method to get memory size
* Remove extra line that was a pre-existing typo
Signed-off-by: Kevin May <kevin.may@arm.com>
Change-Id: I807fc6b5d6fe32b28975ae2a98a6179712c26a96
diff --git a/ArmnnPreparedModel_1_2.cpp b/ArmnnPreparedModel_1_2.cpp
index c129fd6..83e4aac 100644
--- a/ArmnnPreparedModel_1_2.cpp
+++ b/ArmnnPreparedModel_1_2.cpp
@@ -285,7 +285,7 @@
return V1_0::ErrorStatus::OUTPUT_INSUFFICIENT_SIZE;
}
#else
- const size_t bufferSize = memPools.at(outputArg.location.poolIndex).getMemory().size;
+ const size_t bufferSize = memPools.at(outputArg.location.poolIndex).getSize();
if (bufferSize < outputSize)
{
ALOGW("ArmnnPreparedModel_1_2::Execute failed bufferSize (%s) < outputSize (%s)",
diff --git a/ArmnnPreparedModel_1_3.cpp b/ArmnnPreparedModel_1_3.cpp
index 5a37032..6391872 100644
--- a/ArmnnPreparedModel_1_3.cpp
+++ b/ArmnnPreparedModel_1_3.cpp
@@ -492,9 +492,8 @@
size_t bufferSize = 0;
#if !defined(ARMNN_ANDROID_S)
bufferSize = memPools.at(outputArg.location.poolIndex).getHidlMemory().size();
- if (bufferSize < outputSize)
#else
- bufferSize = memPools.at(outputArg.location.poolIndex).getMemory().size;
+ bufferSize = memPools.at(outputArg.location.poolIndex).getSize();
#endif
if (bufferSize < outputSize)
{