Opened 14 months ago

Closed 14 months ago

Last modified 14 months ago

#10591 closed defect (wontfix)

-err_detect crccheck and explode+crccheck are broken for flac files

Reported by: Balling Owned by:
Priority: normal Component: avcodec
Version: git-master Keywords: flac crc regression
Cc: Blocked By:
Blocking: Reproduced by developer: no
Analyzed by developer: no

Description

Summary of the bug: use https://files.catbox.moe/kvvrac.flac it was printing "CRC error at PTS 29583360" but it no longer warns about it. Regression of #2266 probably because of #9621. It is problematic that line https://github.com/FFmpeg/FFmpeg/blob/56085e057ff2d2da180a5d56bdd1efd70d53e662/libavcodec/flacdec.c#L772 is dead code now.
How to reproduce:

% ffmpeg -err_detect crccheck -i https://files.catbox.moe/kvvrac.flac -f null -

Patches should be submitted to the ffmpeg-devel mailing list and not this bug tracker.

Change History (7)

comment:1 by Elon Musk, 14 months ago

Component: avcodecundetermined
Keywords: flac crc regression removed
Resolution: invalid
Status: newclosed
Version: git-masterunspecified

Not proof of anything. Just some statements that have no hard evidence.
If you knew how to check you would know that code at line 772 is still always executed.

comment:2 by Balling, 14 months ago

Component: undeterminedavcodec
Resolution: invalid
Status: closedreopened
Version: unspecifiedgit-master

Before:

ffmpeg version git-2020-08-31-4a11a6f Copyright (c) 2000-2020 the FFmpeg developers
  built with gcc 10.2.1 (GCC) 20200805
  configuration: --enable-gpl --enable-version3 --enable-sdl2 --enable-fontconfig --enable-gnutls --enable-iconv --enable-libass --enable-libdav1d --enable-libbluray --enable-libfreetype --enable-libmp3lame --enable-libopencore-amrnb --enable-libopencore-amrwb --enable-libopenjpeg --enable-libopus --enable-libshine --enable-libsnappy --enable-libsoxr --enable-libsrt --enable-libtheora --enable-libtwolame --enable-libvpx --enable-libwavpack --enable-libwebp --enable-libx264 --enable-libx265 --enable-libxml2 --enable-libzimg --enable-lzma --enable-zlib --enable-gmp --enable-libvidstab --enable-libvmaf --enable-libvorbis --enable-libvo-amrwbenc --enable-libmysofa --enable-libspeex --enable-libxvid --enable-libaom --enable-libgsm --enable-librav1e --enable-libsvtav1 --disable-w32threads --enable-libmfx --enable-ffnvcodec --enable-cuda-llvm --enable-cuvid --enable-d3d11va --enable-nvenc --enable-nvdec --enable-dxva2 --enable-avisynth --enable-libopenmpt --enable-amf
  libavutil      56. 58.100 / 56. 58.100
  libavcodec     58.101.101 / 58.101.101
  libavformat    58. 51.101 / 58. 51.101
  libavdevice    58. 11.101 / 58. 11.101
  libavfilter     7. 87.100 /  7. 87.100
  libswscale      5.  8.100 /  5.  8.100
  libswresample   3.  8.100 /  3.  8.100
  libpostproc    55.  8.100 / 55.  8.100
Input #0, flac, from 'kvvrac.flac':
  Metadata:
    ARTIST          : Van Morrison
    Title           : See Me Through > Soldier Of Fortune > Thank You Falletin Me Be Mice Elf Agin > Burning Ground
    ALBUM           : Playhouse Theatre, Edinburgh, Scotland (1999-04-02)
    Date            : 1999-04-02
    track           : 07
    comment         : Encoded by FLAC v1.1.2a with FLAC Frontend v1.7.1; CD 2
  Duration: 00:17:55.21, start: 0.000000, bitrate: 589 kb/s
    Stream #0:0: Audio: flac, 44100 Hz, stereo, s16
Stream mapping:
  Stream #0:0 -> #0:0 (flac (native) -> pcm_s16le (native))
Press [q] to stop, [?] for help
Output #0, null, to 'pipe:':
  Metadata:
    ARTIST          : Van Morrison
    Title           : See Me Through > Soldier Of Fortune > Thank You Falletin Me Be Mice Elf Agin > Burning Ground
    ALBUM           : Playhouse Theatre, Edinburgh, Scotland (1999-04-02)
    Date            : 1999-04-02
    track           : 07
    comment         : Encoded by FLAC v1.1.2a with FLAC Frontend v1.7.1; CD 2
    encoder         : Lavf58.51.101
    Stream #0:0: Audio: pcm_s16le, 44100 Hz, stereo, s16, 1411 kb/s
    Metadata:
      encoder         : Lavc58.101.101 pcm_s16le
[flac @ 000001de24b1a380] CRC error at PTS 29583360
size=N/A time=00:17:55.21 bitrate=N/A speed=2.17e+03x
video:0kB audio:185222kB subtitle:0kB other streams:0kB global headers:0kB muxing overhead: unknown

After:

ffmpeg version N-111995-g5f8c113b75-20230909 Copyright (c) 2000-2023 the FFmpeg developers
  built with gcc 13.1.0 (crosstool-NG 1.25.0.196_227d99d)
  configuration: --prefix=/ffbuild/prefix --pkg-config-flags=--static --pkg-config=pkg-config --cross-prefix=x86_64-w64-mingw32- --arch=x86_64 --target-os=mingw32 --enable-gpl --enable-version3 --disable-debug --enable-shared --disable-static --disable-w32threads --enable-pthreads --enable-iconv --enable-libxml2 --enable-zlib --enable-libfreetype --enable-libfribidi --enable-gmp --enable-lzma --enable-fontconfig --enable-libvorbis --enable-opencl --disable-libpulse --enable-libvmaf --disable-libxcb --disable-xlib --enable-amf --enable-libaom --enable-libaribb24 --enable-avisynth --enable-chromaprint --enable-libdav1d --enable-libdavs2 --disable-libfdk-aac --enable-ffnvcodec --enable-cuda-llvm --enable-frei0r --enable-libgme --enable-libkvazaar --enable-libass --enable-libbluray --enable-libjxl --enable-libmp3lame --enable-libopus --enable-librist --enable-libssh --enable-libtheora --enable-libvpx --enable-libwebp --enable-lv2 --enable-libvpl --enable-openal --enable-libopencore-amrnb --enable-libopencore-amrwb --enable-libopenh264 --enable-libopenjpeg --enable-libopenmpt --enable-librav1e --enable-librubberband --enable-schannel --enable-sdl2 --enable-libsoxr --enable-libsrt --enable-libsvtav1 --enable-libtwolame --enable-libuavs3d --disable-libdrm --disable-vaapi --enable-libvidstab --enable-vulkan --enable-libshaderc --enable-libplacebo --enable-libx264 --enable-libx265 --enable-libxavs2 --enable-libxvid --enable-libzimg --enable-libzvbi --extra-cflags=-DLIBTWOLAME_STATIC --extra-cxxflags= --extra-ldflags=-pthread --extra-ldexeflags= --extra-libs=-lgomp --extra-version=20230909
  libavutil      58. 19.100 / 58. 19.100
  libavcodec     60. 26.100 / 60. 26.100
  libavformat    60. 11.100 / 60. 11.100
  libavdevice    60.  2.101 / 60.  2.101
  libavfilter     9. 11.100 /  9. 11.100
  libswscale      7.  3.100 /  7.  3.100
  libswresample   4. 11.100 /  4. 11.100
  libpostproc    57.  2.100 / 57.  2.100
Input #0, flac, from 'kvvrac.flac':
  Metadata:
    ARTIST          : Van Morrison
    Title           : See Me Through > Soldier Of Fortune > Thank You Falletin Me Be Mice Elf Agin > Burning Ground
    ALBUM           : Playhouse Theatre, Edinburgh, Scotland (1999-04-02)
    Date            : 1999-04-02
    track           : 07
    comment         : Encoded by FLAC v1.1.2a with FLAC Frontend v1.7.1; CD 2
  Duration: 00:17:55.21, start: 0.000000, bitrate: 589 kb/s
  Stream #0:0: Audio: flac, 44100 Hz, stereo, s16
Stream mapping:
  Stream #0:0 -> #0:0 (flac (native) -> pcm_s16le (native))
Press [q] to stop, [?] for help
Output #0, null, to 'pipe:':
  Metadata:
    ARTIST          : Van Morrison
    Title           : See Me Through > Soldier Of Fortune > Thank You Falletin Me Be Mice Elf Agin > Burning Ground
    ALBUM           : Playhouse Theatre, Edinburgh, Scotland (1999-04-02)
    Date            : 1999-04-02
    track           : 07
    comment         : Encoded by FLAC v1.1.2a with FLAC Frontend v1.7.1; CD 2
    encoder         : Lavf60.11.100
  Stream #0:0: Audio: pcm_s16le, 44100 Hz, stereo, s16, 1411 kb/s
    Metadata:
      encoder         : Lavc60.26.100 pcm_s16le
[out#0/null @ 00000253f9edeb40] video:0kB audio:185168kB subtitle:0kB other streams:0kB global headers:0kB muxing overhead: unknown
size=N/A time=00:17:55.20 bitrate=N/A speed=1.2e+03x

comment:3 by Balling, 14 months ago

I am really tired of this, here is a file where I changed one byte randomly, same happens on it: https://0x0.st/HVQc.flac


comment:4 by Balling, 14 months ago

Keywords: flac crc regression added
Summary: -err_detect crccheck is again broken for flac files-err_detect crccheck and explode+crccheck are broken for flac files

comment:5 by Elon Musk, 14 months ago

Resolution: wontfix
Status: reopenedclosed

comment:6 by Balling, 14 months ago

Why? Chrome uses explode, this means bad flac files will pass through. I did not notice that other issue, but that is worse.

Of course it is more or less cosmetic, but still. Do you like dead log code?

comment:7 by Balling, 14 months ago

How do you trigger line 722 and line 774? Can you at least remove dead code and add a warning for underread.

Note: See TracTickets for help on using tickets.