From 3fad524089c2d22cfc289814ddbe4abd9ee7a76a Mon Sep 17 00:00:00 2001 From: kim Date: Sat, 16 Aug 2025 15:16:00 +0200 Subject: [PATCH] [bugfix] when clearing media metadata, copy all streams not just first (#4375) Updates our ffmpeg metadata clearing arguments to copy all streams when copying codecs, not just the first of each. closes https://codeberg.org/superseriousbusiness/gotosocial/issues/4312 Reviewed-on: https://codeberg.org/superseriousbusiness/gotosocial/pulls/4375 Co-authored-by: kim Co-committed-by: kim --- internal/media/ffmpeg.go | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/internal/media/ffmpeg.go b/internal/media/ffmpeg.go index 05e8c69a6..d98e93baf 100644 --- a/internal/media/ffmpeg.go +++ b/internal/media/ffmpeg.go @@ -55,6 +55,12 @@ func ffmpegClearMetadata(ctx context.Context, outpath, inpath string) error { // i.e. no transcode. "-codec", "copy", + // Ensure we include + // ALL audio / video + // / subtitle streams, + // not just the first. + "-map", "0", + // Overwrite. "-y",