OSDN Git Service

Fix for issue 5490443 Native crash while exporting a video
authorHong Teng <hongteng@google.com>
Thu, 1 Dec 2011 00:42:56 +0000 (16:42 -0800)
committerHong Teng <hongteng@google.com>
Thu, 1 Dec 2011 01:35:58 +0000 (17:35 -0800)
Handle the decoder error case, this modification is to fix the native crash.

Change-Id: I3f2ef62b591ebfb9e01153b80b04eb330f575207

libvideoeditor/vss/stagefrightshells/src/VideoEditorVideoDecoder.cpp

index 0d5ea64..82e149b 100755 (executable)
@@ -1396,6 +1396,11 @@ M4OSA_ERR VideoEditorVideoDecoder_decode(M4OSA_Context context,
                 break;
             }
             continue;
+        } else if (errStatus != OK) {
+            LOGE("VideoEditorVideoDecoder_decode ERROR:0x%x(%d)",
+                errStatus,errStatus);
+            lerr = errStatus;
+            goto VIDEOEDITOR_VideoDecode_cleanUP;
         }
 
         // The OMXCodec client should expect to receive 0-length buffers