diff options
author | Stefano Sabatini <stefasab@gmail.com> | 2012-12-20 13:41:19 +0400 |
---|---|---|
committer | Stefano Sabatini <stefasab@gmail.com> | 2012-12-21 03:07:21 +0400 |
commit | 340b7caf5457b2988bfd53709a00cedc2fcd73b7 (patch) | |
tree | a1ec7ef4b6254d411e341e2b055512167f304b4b /libavformat/hlsenc.c | |
parent | 28b96efab509801ed9d81bb84ed42adb9c4de84f (diff) |
lavf/hlsenc: provide some feedback in case of invalid basename
Diffstat (limited to 'libavformat/hlsenc.c')
-rw-r--r-- | libavformat/hlsenc.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/libavformat/hlsenc.c b/libavformat/hlsenc.c index b92a39b246..d5058a1a5e 100644 --- a/libavformat/hlsenc.c +++ b/libavformat/hlsenc.c @@ -157,8 +157,10 @@ static int hls_start(AVFormatContext *s) c->number %= c->wrap; if (av_get_frame_filename(oc->filename, sizeof(oc->filename), - c->basename, c->number++) < 0) + c->basename, c->number++) < 0) { + av_log(oc, AV_LOG_ERROR, "Invalid segment filename template '%s'\n", c->basename); return AVERROR(EINVAL); + } if ((err = avio_open2(&oc->pb, oc->filename, AVIO_FLAG_WRITE, &s->interrupt_callback, NULL)) < 0) |