]> git.sesse.net Git - ffmpeg/blobdiff - libavcodec/h261_parser.c
Use MAP_FAILED to check for mmap failure instead of manually
[ffmpeg] / libavcodec / h261_parser.c
index 4d20afe8d6edbab1d0d489a48bf1c1335943112a..3fb86db1255c30ec95b283fbae9391f8da351465 100644 (file)
@@ -73,12 +73,12 @@ static int h261_parse(AVCodecParserContext *s,
     if (s->flags & PARSER_FLAG_COMPLETE_FRAMES) {
         next = buf_size;
     } else {
-    next= h261_find_frame_end(pc,avctx, buf, buf_size);
-    if (ff_combine_frame(pc, next, &buf, &buf_size) < 0) {
-        *poutbuf = NULL;
-        *poutbuf_size = 0;
-        return buf_size;
-    }
+        next= h261_find_frame_end(pc,avctx, buf, buf_size);
+        if (ff_combine_frame(pc, next, &buf, &buf_size) < 0) {
+            *poutbuf = NULL;
+            *poutbuf_size = 0;
+            return buf_size;
+        }
     }
     *poutbuf = buf;
     *poutbuf_size = buf_size;