[FFmpeg-cvslog] ffserver: improve feedback in case no feed is defined for a stream

Stefano Sabatini git at videolan.org
Fri Nov 29 12:13:17 CET 2013


ffmpeg | branch: master | Stefano Sabatini <stefasab at gmail.com> | Fri Nov 29 11:47:01 2013 +0100| [b133ec62443022de48126cba9352ffefed6b4709] | committer: Stefano Sabatini

ffserver: improve feedback in case no feed is defined for a stream

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

 ffserver.c |    7 ++++++-
 1 file changed, 6 insertions(+), 1 deletion(-)

diff --git a/ffserver.c b/ffserver.c
index 46c08d2..469046a 100644
--- a/ffserver.c
+++ b/ffserver.c
@@ -3690,7 +3690,12 @@ static void build_file_streams(void)
                 av_dict_set(&stream->in_opts, "mpeg2ts_compute_pcr", "1", 0);
             }
 
-            http_log("Opening file '%s'\n", stream->feed_filename);
+            if (!stream->feed_filename[0]) {
+                http_log("Unspecified feed file for stream '%s'\n", stream->filename);
+                goto fail;
+            }
+
+            http_log("Opening feed file '%s' for stream '%s'\n", stream->feed_filename, stream->filename);
             if ((ret = avformat_open_input(&infile, stream->feed_filename, stream->ifmt, &stream->in_opts)) < 0) {
                 http_log("Could not open '%s': %d\n", stream->feed_filename, ret);
                 /* remove stream (no need to spend more time on it) */



More information about the ffmpeg-cvslog mailing list