Android-x86
Fork
Faire un don

  • R/O
  • HTTP
  • SSH
  • HTTPS

hardware-interfaces: Commit

hardware/interfaces


Commit MetaInfo

Révisiona0698429dd47e2f029866765c6980bc8720a7acb (tree)
l'heure2017-10-17 20:34:30
AuteurRam Mohan M <ram.mohan@itti...>
CommiterPawin Vongmasa

Message de Log

bug fix: during fatal fails bypass freeNode() calls

If test application undergoes a fatal failure bypass all the omx
api calls till the application safely returns.

Test: make vts -j99 BUILD_GOOGLE_VTS=true TARGET_PRODUCT=aosp_arm64 \
&& vts-tradefed run commandAndExit vts \
--skip-all-system-status-check --primary-abi-only \
--skip-preconditions --module VtsHalMediaOmxV1_0Host \
-l INFO

Bug: 63796949

Change-Id: If5a33672a31665db913e53c6f8ba8bea6cfd3ebd

Change Summary

Modification

--- a/media/omx/1.0/vts/functional/audio/VtsHalMediaOmxV1_0TargetAudioDecTest.cpp
+++ b/media/omx/1.0/vts/functional/audio/VtsHalMediaOmxV1_0TargetAudioDecTest.cpp
@@ -230,6 +230,10 @@ class AudioDecHidlTest : public ::testing::VtsHalHidlTargetTestBase {
230230
231231 virtual void TearDown() override {
232232 if (omxNode != nullptr) {
233+ // If you have encountered a fatal failure, it is possible that
234+ // freeNode() will not go through. Instead of hanging the app.
235+ // let it pass through and report errors
236+ if (::testing::Test::HasFatalFailure()) return;
233237 EXPECT_TRUE((omxNode->freeNode()).isOk());
234238 omxNode = nullptr;
235239 }
--- a/media/omx/1.0/vts/functional/audio/VtsHalMediaOmxV1_0TargetAudioEncTest.cpp
+++ b/media/omx/1.0/vts/functional/audio/VtsHalMediaOmxV1_0TargetAudioEncTest.cpp
@@ -216,6 +216,10 @@ class AudioEncHidlTest : public ::testing::VtsHalHidlTargetTestBase {
216216
217217 virtual void TearDown() override {
218218 if (omxNode != nullptr) {
219+ // If you have encountered a fatal failure, it is possible that
220+ // freeNode() will not go through. Instead of hanging the app.
221+ // let it pass through and report errors
222+ if (::testing::Test::HasFatalFailure()) return;
219223 EXPECT_TRUE((omxNode->freeNode()).isOk());
220224 omxNode = nullptr;
221225 }
--- a/media/omx/1.0/vts/functional/component/VtsHalMediaOmxV1_0TargetComponentTest.cpp
+++ b/media/omx/1.0/vts/functional/component/VtsHalMediaOmxV1_0TargetComponentTest.cpp
@@ -191,6 +191,10 @@ class ComponentHidlTest : public ::testing::VtsHalHidlTargetTestBase {
191191
192192 virtual void TearDown() override {
193193 if (omxNode != nullptr) {
194+ // If you have encountered a fatal failure, it is possible that
195+ // freeNode() will not go through. Instead of hanging the app.
196+ // let it pass through and report errors
197+ if (::testing::Test::HasFatalFailure()) return;
194198 EXPECT_TRUE((omxNode->freeNode()).isOk());
195199 omxNode = nullptr;
196200 }
--- a/media/omx/1.0/vts/functional/video/VtsHalMediaOmxV1_0TargetVideoDecTest.cpp
+++ b/media/omx/1.0/vts/functional/video/VtsHalMediaOmxV1_0TargetVideoDecTest.cpp
@@ -232,6 +232,10 @@ class VideoDecHidlTest : public ::testing::VtsHalHidlTargetTestBase {
232232
233233 virtual void TearDown() override {
234234 if (omxNode != nullptr) {
235+ // If you have encountered a fatal failure, it is possible that
236+ // freeNode() will not go through. Instead of hanging the app.
237+ // let it pass through and report errors
238+ if (::testing::Test::HasFatalFailure()) return;
235239 EXPECT_TRUE((omxNode->freeNode()).isOk());
236240 omxNode = nullptr;
237241 }
--- a/media/omx/1.0/vts/functional/video/VtsHalMediaOmxV1_0TargetVideoEncTest.cpp
+++ b/media/omx/1.0/vts/functional/video/VtsHalMediaOmxV1_0TargetVideoEncTest.cpp
@@ -243,6 +243,10 @@ class VideoEncHidlTest : public ::testing::VtsHalHidlTargetTestBase {
243243
244244 virtual void TearDown() override {
245245 if (omxNode != nullptr) {
246+ // If you have encountered a fatal failure, it is possible that
247+ // freeNode() will not go through. Instead of hanging the app.
248+ // let it pass through and report errors
249+ if (::testing::Test::HasFatalFailure()) return;
246250 EXPECT_TRUE((omxNode->freeNode()).isOk());
247251 omxNode = nullptr;
248252 }
Afficher sur ancien navigateur de dépôt.