diff --git a/yt_dlp/YoutubeDL.py b/yt_dlp/YoutubeDL.py index 9691a1ea7c..a571f4ede3 100644 --- a/yt_dlp/YoutubeDL.py +++ b/yt_dlp/YoutubeDL.py @@ -3546,7 +3546,8 @@ def ffmpeg_fixup(cndn, msg, cls): 'writing DASH m4a. Only some players support this container', FFmpegFixupM4aPP) ffmpeg_fixup(downloader == 'hlsnative' and not self.params.get('hls_use_mpegts') - or info_dict.get('is_live') and self.params.get('hls_use_mpegts') is None, + or info_dict.get('is_live') and self.params.get('hls_use_mpegts') is None + or downloader == 'niconico_live', 'Possible MPEG-TS in MP4 container or malformed AAC timestamps', FFmpegFixupM3u8PP) ffmpeg_fixup(downloader == 'dashsegments' diff --git a/yt_dlp/downloader/__init__.py b/yt_dlp/downloader/__init__.py index 9f6385058c..51a9f28f06 100644 --- a/yt_dlp/downloader/__init__.py +++ b/yt_dlp/downloader/__init__.py @@ -50,7 +50,7 @@ def get_suitable_downloader(info_dict, params={}, default=NO_DEFAULT, protocol=N 'ism': IsmFD, 'mhtml': MhtmlFD, 'niconico_dmc': NiconicoDmcFD, - 'm3u8_niconico_live': NiconicoLiveFD, + 'niconico_live': NiconicoLiveFD, 'fc2_live': FC2LiveFD, 'websocket_frag': WebSocketFragmentFD, 'youtube_live_chat': YoutubeLiveChatFD, diff --git a/yt_dlp/extractor/niconico.py b/yt_dlp/extractor/niconico.py index 9649329327..11d23f5af1 100644 --- a/yt_dlp/extractor/niconico.py +++ b/yt_dlp/extractor/niconico.py @@ -1007,7 +1007,7 @@ def _yield_formats(self, ws_url, headers, latency, video_id, is_live): for fmt, q in zip(formats, reversed(qualities[1:])): fmt.update({ 'format_id': q, - 'protocol': 'm3u8_niconico_live', + 'protocol': 'niconico_live', }) yield fmt diff --git a/yt_dlp/postprocessor/ffmpeg.py b/yt_dlp/postprocessor/ffmpeg.py index 164c46d143..422aab8242 100644 --- a/yt_dlp/postprocessor/ffmpeg.py +++ b/yt_dlp/postprocessor/ffmpeg.py @@ -888,7 +888,7 @@ def run(self, info): class FFmpegFixupM3u8PP(FFmpegFixupPostProcessor): def _needs_fixup(self, info): yield info['ext'] in ('mp4', 'm4a') - yield info['protocol'].startswith('m3u8') + yield info['protocol'].startswith('m3u8') or info['protocol'] == 'niconico_live' try: metadata = self.get_metadata_object(info['filepath']) except PostProcessingError as e: