HydrogenAudio

Hosted Forums => foobar2000 => Support - (fb2k) => Topic started by: lvqcl on 2013-02-28 15:31:20

Title: Crash in foo_input_std
Post by: lvqcl on 2013-02-28 15:31:20
Take a WAV file in WAVE_FORMAT_EXTENSIBLE format with wValidBitsPerSample == 20 and wBitsPerSample == 24.
Compress it to FLAC or Wavpack (cmdline encoders).

fb2k cannot verify integrity of such files: it crashes. No problems with the original WAV file though.
Title: Crash in foo_input_std
Post by: Peter on 2013-03-05 13:59:10
This is most interesting, thanks for the report.
Title: Crash in foo_input_std
Post by: lvqcl on 2013-03-14 16:58:21
On the other hand, fb2k doesn't crash if wBitsPerSample == 24 and wValidBitsPerSample == 16.

AND: FLAC calculates MD5 of such files differently than WavPack, TAK (http://www.hydrogenaudio.org/forums/index.php?s=&showtopic=54087&view=findpost&p=827368) and OFR. (I wrote about it: http://www.hydrogenaudio.org/forums/index....st&p=827385 (http://www.hydrogenaudio.org/forums/index.php?s=&showtopic=99757&view=findpost&p=827385) )
Title: Crash in foo_input_std
Post by: lvqcl on 2013-03-18 15:19:59
I took Garbage sample from this thread (http://www.hydrogenaudio.org/forums/index.php?showtopic=78476) and converted it to 3-bit pcm so it's possible to test various BitsPerSample / ValidBitsPerSample combinations: [attachment=7432:wValidBitsPerSample.7z]

fb2k 1.2.4 b1 doesn't crash but it doesn't cover some exotic cases (the result is MD5 mismatch for WavPack and Unsupported format or corrupted file for FLAC)
Title: Crash in foo_input_std
Post by: Peter on 2013-03-22 13:44:02
Thanks for the detailed report.

FLAC with bit depth below 8 = fixed for the next update after 1.2.4 beta 3.
Exotic cases of WavPack bit depth configs (with 8 or more bits wasted) currently fail checksumming, I'll need to add special handling for these.