[PATCH 07/12] Make av_open_input_file() return AVERROR_INVALIDDATA rather than AV_NOFMT if the format is unknown / cannot be recognized.

Stefano Sabatini stefano.sabatini-lala
Wed Mar 17 00:36:45 CET 2010


It is returned AVERROR_INVALIDDATA, in the sense that the data is
invalid within what the specific libav* binary supports.

That was the only use of AVERROR_NOFMT, which is going to be dropped.
---
 libavformat/utils.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/libavformat/utils.c b/libavformat/utils.c
index d9478db..db1dc14 100644
--- a/libavformat/utils.c
+++ b/libavformat/utils.c
@@ -560,7 +560,7 @@ int av_open_input_file(AVFormatContext **ic_ptr, const char *filename,
 
     /* if still no format found, error */
     if (!fmt) {
-        err = AVERROR_NOFMT;
+        err = AVERROR_INVALIDDATA;
         goto fail;
     }
 
-- 
1.7.0


--h31gzZEtNLTqOjlF--



More information about the ffmpeg-devel mailing list