summaryrefslogtreecommitdiffstats
path: root/libstagefrighthw
diff options
context:
space:
mode:
authorJames Dong <jdong@google.com>2012-02-08 12:58:33 -0800
committerJames Dong <jdong@google.com>2012-02-10 13:35:26 -0800
commit8addb43c8e7056e8a941318ce734274951e968b7 (patch)
tree40596c1c303d8bada1de499b685e326a2098b3d3 /libstagefrighthw
parent2f7b53283dc45a209c65a9aaf8d62b7ced953ef3 (diff)
downloaddevice_samsung_crespo-8addb43c8e7056e8a941318ce734274951e968b7.zip
device_samsung_crespo-8addb43c8e7056e8a941318ce734274951e968b7.tar.gz
device_samsung_crespo-8addb43c8e7056e8a941318ce734274951e968b7.tar.bz2
Do not use MediaDebug in libstagefrighthw.
Change-Id: If84f2ff815cc1cc0efdaded491784b0257a18532
Diffstat (limited to 'libstagefrighthw')
-rw-r--r--libstagefrighthw/SEC_OMX_Plugin.cpp14
1 files changed, 8 insertions, 6 deletions
diff --git a/libstagefrighthw/SEC_OMX_Plugin.cpp b/libstagefrighthw/SEC_OMX_Plugin.cpp
index efc8691..82497aa 100644
--- a/libstagefrighthw/SEC_OMX_Plugin.cpp
+++ b/libstagefrighthw/SEC_OMX_Plugin.cpp
@@ -19,7 +19,6 @@
#include <dlfcn.h>
#include <media/stagefright/HardwareAPI.h>
-#include <media/stagefright/MediaDebug.h>
namespace android {
@@ -125,12 +124,15 @@ OMX_ERRORTYPE SECOMXPlugin::getRolesOfComponent(
err = (*mGetRolesOfComponentHandle)(
const_cast<OMX_STRING>(name), &numRoles2, array);
- CHECK_EQ(err, OMX_ErrorNone);
- CHECK_EQ(numRoles, numRoles2);
+ if (err == OMX_ErrorNone && numRoles != numRoles2) {
+ err = OMX_ErrorUndefined;
+ }
for (OMX_U32 i = 0; i < numRoles; ++i) {
- String8 s((const char *)array[i]);
- roles->push(s);
+ if (err == OMX_ErrorNone) {
+ String8 s((const char *)array[i]);
+ roles->push(s);
+ }
delete[] array[i];
array[i] = NULL;
@@ -140,7 +142,7 @@ OMX_ERRORTYPE SECOMXPlugin::getRolesOfComponent(
array = NULL;
}
- return OMX_ErrorNone;
+ return err;
}
} // namespace android