Since commit 934f2d2f5c16df8aad9f401a9fd842b5d9a78b11,
cmdutils_read_file() prints a confusing message on success:

IO error: Success

This is because the error message is printed on the success path as
well. Add the missing condition so that it is only printed on error.

Signed-off-by: Jean Delvare <jdelv...@suse.de>
Cc: Michael Niedermayer <michae...@gmx.at>
---
 cmdutils.c |    3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

--- ffmpeg.orig/cmdutils.c      2015-02-11 14:01:08.995929450 +0100
+++ ffmpeg/cmdutils.c   2015-02-11 14:02:30.827593418 +0100
@@ -1912,7 +1912,8 @@ int cmdutils_read_file(const char *filen
     }
 
 out:
-    av_log(NULL, AV_LOG_ERROR, "IO error: %s\n", av_err2str(ret));
+    if (ret < 0)
+       av_log(NULL, AV_LOG_ERROR, "IO error: %s\n", av_err2str(ret));
     fclose(f);
     return ret;
 }


-- 
Jean Delvare
SUSE L3 Support
_______________________________________________
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-devel

Reply via email to