You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I spent an eternity tracking this down, but on pc-windows-msvc, with simplemad 0.9.0, simplemad_sys 0.5.0, and rustc 1.67.0-nightly (c1a859b25 2022-11-10), creating a Decoder instance on a file that exists, has data, and a valid reader returns Err(EOF). I have a minimal example here:
The variable header->layer is being initialized to 0, but 0 is not a valid enum value for enum mad_layer, which can only have 1, 2, or 3. I'm not sure why this causes Rust to freak out (but only on nightly), but changing that line in frame.c to:
header->layer=MAD_LAYER_I;
fixes it when running against nightly.
The text was updated successfully, but these errors were encountered:
I spent an eternity tracking this down, but on
pc-windows-msvc
, with simplemad 0.9.0, simplemad_sys 0.5.0, and rustc 1.67.0-nightly (c1a859b25 2022-11-10), creating aDecoder
instance on a file that exists, has data, and a valid reader returnsErr(EOF)
. I have a minimal example here:https://github.com/ahwatts/simplemad-test
Running it against stable:
And the output of running it with nightly:
It looks like the issue is here:
https://github.com/RustAudio/simplemad/blob/master/simplemad_sys/libmad-src/frame.c#L70
The variable
header->layer
is being initialized to 0, but 0 is not a valid enum value forenum mad_layer
, which can only have 1, 2, or 3. I'm not sure why this causes Rust to freak out (but only on nightly), but changing that line inframe.c
to:fixes it when running against nightly.
The text was updated successfully, but these errors were encountered: