ffmpeg | branch: master | Steven Liu <[email protected]> | Tue Aug 20 10:31:01 2019 +0800| [fa78a6abb379f9e8193bd02821aba006bd092ed4] | committer: Steven Liu
avformat/hlsenc: simplified code of use_localtime in hls_init Signed-off-by: Steven Liu <[email protected]> > http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=fa78a6abb379f9e8193bd02821aba006bd092ed4 --- libavformat/hlsenc.c | 15 ++++----------- 1 file changed, 4 insertions(+), 11 deletions(-) diff --git a/libavformat/hlsenc.c b/libavformat/hlsenc.c index c740cf2c56..9511b65e2d 100644 --- a/libavformat/hlsenc.c +++ b/libavformat/hlsenc.c @@ -2875,17 +2875,10 @@ static int hls_init(AVFormatContext *s) } } - if (!hls->use_localtime) { - ret = sls_flag_check_duration_size_index(hls); - if (ret < 0) { - goto fail; - } - } else { - ret = sls_flag_check_duration_size(hls, vs); - if (ret < 0) { - goto fail; - } - } + ret = hls->use_localtime ? sls_flag_check_duration_size(hls, vs) : sls_flag_check_duration_size_index(hls); + if (ret < 0) + goto fail; + if (vs->has_subtitle) { if (hls->flags & HLS_SINGLE_FILE) _______________________________________________ ffmpeg-cvslog mailing list [email protected] https://ffmpeg.org/mailman/listinfo/ffmpeg-cvslog To unsubscribe, visit link above, or email [email protected] with subject "unsubscribe".
