[FFmpeg-soc] [PATCH] Fix bug in vsrc_movie.c

Brandon Mintern bmintern at gmail.com
Thu Apr 1 02:56:41 CEST 2010


I e-mailed this to the list before, but I think it may have been
overlooked because I didn't prepend my post with "[PATCH]". When
looking at init() in vsrc_movie.c, I noticed that there was an
improperly-indented else statement, and looking at the code there
appears to be a bug in the error-handling logic. Presumably, when
"movie" is called with no args, it will fail without reporting an
error. The patch to fix this issue is below.

- Brandon

Index: vsrc_movie.c
===================================================================
--- vsrc_movie.c	(revision 5726)
+++ vsrc_movie.c	(working copy)
@@ -140,9 +140,8 @@
             // sanity check parms
             if (mv->seek_point >= 0 && *mv->file_name)
                 return movie_init(ctx);
-        }
-        else
-            av_log(ctx, AV_LOG_ERROR, "init() expected 3
arguments:'%s'\n", args);
+    }
+    av_log(ctx, AV_LOG_ERROR, "init() expected 3 arguments:'%s'\n", args);
     return -1;
 }


More information about the FFmpeg-soc mailing list