OSDN Git Service

OMXNodeInstance: actually fix OMX_GetExtIndex logging
authorJamie Gennis <jgennis@google.com>
Thu, 18 Apr 2013 23:34:44 +0000 (16:34 -0700)
committerJamie Gennis <jgennis@google.com>
Thu, 18 Apr 2013 23:45:24 +0000 (16:45 -0700)
Bug: 8538872
Change-Id: I228746e8eb502af4bba4054caa4d8569fab35025

media/libstagefright/omx/OMXNodeInstance.cpp

index 971875f..e7d5e74 100644 (file)
@@ -299,7 +299,9 @@ status_t OMXNodeInstance::enableGraphicBuffers(
     OMX_ERRORTYPE err = OMX_GetExtensionIndex(mHandle, name, &index);
 
     if (err != OMX_ErrorNone) {
-        ALOGE("OMX_GetExtensionIndex %s failed", name);
+        if (enable) {
+            ALOGE("OMX_GetExtensionIndex %s failed", name);
+        }
 
         return StatusFromOMXError(err);
     }
@@ -378,9 +380,8 @@ status_t OMXNodeInstance::storeMetaDataInBuffers_l(
 
     OMX_ERRORTYPE err = OMX_GetExtensionIndex(mHandle, name, &index);
     if (err != OMX_ErrorNone) {
-        if (enable) {
-            ALOGE("OMX_GetExtensionIndex %s failed", name);
-        }
+        ALOGE("OMX_GetExtensionIndex %s failed", name);
+
         return StatusFromOMXError(err);
     }