[FFmpeg-cvslog] avprobe: Identify codec probe failures rather than calling them unsupported codecs.

Alex Converse git at videolan.org
Wed Jun 6 01:20:58 CEST 2012


ffmpeg | branch: master | Alex Converse <alex.converse at gmail.com> | Mon Jun  4 17:35:51 2012 -0700| [503f2feb143b58bf9b7850ef00ec0bb02d509f78] | committer: Alex Converse

avprobe: Identify codec probe failures rather than calling them unsupported codecs.

> http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=503f2feb143b58bf9b7850ef00ec0bb02d509f78
---

 avprobe.c |    5 ++++-
 1 file changed, 4 insertions(+), 1 deletion(-)

diff --git a/avprobe.c b/avprobe.c
index 2464f86..8e93d05 100644
--- a/avprobe.c
+++ b/avprobe.c
@@ -733,7 +733,10 @@ static int open_input_file(AVFormatContext **fmt_ctx_ptr, const char *filename)
         AVStream *stream = fmt_ctx->streams[i];
         AVCodec *codec;
 
-        if (!(codec = avcodec_find_decoder(stream->codec->codec_id))) {
+        if (stream->codec->codec_id == CODEC_ID_PROBE) {
+            fprintf(stderr, "Failed to probe codec for input stream %d\n",
+                    stream->index);
+        } else if (!(codec = avcodec_find_decoder(stream->codec->codec_id))) {
             fprintf(stderr,
                     "Unsupported codec with id %d for input stream %d\n",
                     stream->codec->codec_id, stream->index);



More information about the ffmpeg-cvslog mailing list