diff options
author | Steven Liu <lq@chinaffmpeg.org> | 2017-12-04 12:03:37 +0800 |
---|---|---|
committer | Steven Liu <lq@chinaffmpeg.org> | 2017-12-04 12:03:37 +0800 |
commit | 071f47649ce39897f18ce034dd428067f29d9b66 (patch) | |
tree | 730b7777a2b4d6325d075e838894c2481adbd89d /libavformat/dashenc.c | |
parent | 31b351ea81d0a7c0d0ed1982dcc6327b7f43b987 (diff) | |
download | ffmpeg-071f47649ce39897f18ce034dd428067f29d9b66.tar.gz |
avformat/hlsplaylist: add int type of API ff_hls_write_file_entry
Signed-off-by: Steven Liu <lq@chinaffmpeg.org>
Diffstat (limited to 'libavformat/dashenc.c')
-rw-r--r-- | libavformat/dashenc.c | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/libavformat/dashenc.c b/libavformat/dashenc.c index 1783675d00..22ef3103dc 100644 --- a/libavformat/dashenc.c +++ b/libavformat/dashenc.c @@ -342,6 +342,7 @@ static void output_segment_list(OutputStream *os, AVIOContext *out, DASHContext AVIOContext *out_hls = NULL; AVDictionary *http_opts = NULL; int target_duration = 0; + int ret = 0; const char *proto = avio_find_protocol_name(c->dirname); int use_rename = proto && !strcmp(proto, "file"); @@ -368,11 +369,14 @@ static void output_segment_list(OutputStream *os, AVIOContext *out, DASHContext for (i = start_index; i < os->nb_segments; i++) { Segment *seg = os->segments[i]; - ff_hls_write_file_entry(out_hls, 0, c->single_file, + ret = ff_hls_write_file_entry(out_hls, 0, c->single_file, (double) seg->duration / timescale, 0, seg->range_length, seg->start_pos, NULL, c->single_file ? os->initfile : seg->file, NULL); + if (ret < 0) { + av_log(os->ctx, AV_LOG_WARNING, "ff_hls_write_file_entry get error\n"); + } } if (final) |