CCodec: add cast to signed integer
Bug: 116297102
Test: m cts && cts-tradefed run cts -m CtsSecurityTestCases \
-t android.security.cts.StagefrightTest#testStagefright_cve_2016_3755
Test: m cts && cts-tradefed run cts -m CtsMediaTestCases \
-t android.media.cts.MediaCodecTest
Test: m cts && cts-tradefed run cts-dev -m CtsMediaTestCases \
--compatibility:module-arg \
CtsMediaTestCases:include-annotation:\
android.platform.test.annotations.RequiresDevice
Test: m cts && cts-tradefed run cts -m CtsSecurityTestCases
Change-Id: Ic34b85a2e191b219af0189f136e9ed34ae316204
(cherry picked from commit 153dcbeed25d0b076813fb80901876d6745bf262)
diff --git a/media/sfplugin/CCodecBufferChannel.cpp b/media/sfplugin/CCodecBufferChannel.cpp
index bf14e09..b372b3c 100644
--- a/media/sfplugin/CCodecBufferChannel.cpp
+++ b/media/sfplugin/CCodecBufferChannel.cpp
@@ -1405,7 +1405,7 @@
prevInput + static_cast<int>(numDiscardedInputBuffers),
component.load(std::memory_order_relaxed),
output.load(std::memory_order_relaxed));
- return prevInput + numDiscardedInputBuffers;
+ return prevInput + static_cast<int>(numDiscardedInputBuffers);
}
int CCodecBufferChannel::PipelineCapacity::freeComponentSlot(