From 593e0f43b43d5a90d6e3430aeb94357ef81fb1ab Mon Sep 17 00:00:00 2001 From: remitamine Date: Fri, 5 Feb 2016 15:12:06 +0100 Subject: [PATCH] [ffmpeg] fix condition(fixes #8440) --- youtube_dl/postprocessor/ffmpeg.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/youtube_dl/postprocessor/ffmpeg.py b/youtube_dl/postprocessor/ffmpeg.py index e293e03e6..7e85a702d 100644 --- a/youtube_dl/postprocessor/ffmpeg.py +++ b/youtube_dl/postprocessor/ffmpeg.py @@ -392,7 +392,7 @@ class FFmpegMetadataPP(FFmpegPostProcessor): options.extend(['-metadata', '%s=%s' % (name, value)]) # https://github.com/rg3/youtube-dl/issues/8350 - if info['protocol'] == 'm3u8_native' or self._downloader.params.get('hls_prefer_native', False): + if info.get('protocol') == 'm3u8_native' or self._downloader.params.get('hls_prefer_native', False): options.extend(['-bsf:a', 'aac_adtstoasc']) self._downloader.to_screen('[ffmpeg] Adding metadata to \'%s\'' % filename) -- 2.40.0