avformat/hlsenc: print warning at the end when upload the last segment failed
authorSteven Liu <lq@chinaffmpeg.org>
Sat, 7 Sep 2019 12:39:28 +0000 (20:39 +0800)
committerSteven Liu <lq@chinaffmpeg.org>
Thu, 12 Sep 2019 02:39:15 +0000 (10:39 +0800)
Signed-off-by: Steven Liu <lq@chinaffmpeg.org>
libavformat/hlsenc.c

index e03db5f..c9858f2 100644 (file)
@@ -2601,6 +2601,8 @@ static int hls_write_trailer(struct AVFormatContext *s)
             }
             reflush_dynbuf(vs, &range_length);
             ret = hlsenc_io_close(s, &vs->out, filename);
+            if (ret < 0)
+                av_log(s, AV_LOG_WARNING, "Failed to upload file '%s' at the end.\n", vs->avf->url);
         }
         av_free(vs->temp_buffer);