New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
First 3 bytes of files read from FatFs will be truncated #65
Comments
Likely related to this issue: esp-rs/rust#96 |
Yeah, it seems like this is the same bug. Closing it here in favor of the already existing bug report. |
@derchr |
I remember also testing |
Hi,
I have created a repro for this bug: https://github.com/derchr/repro-fs
Just follow the instructions in the readme and the bug should show up.
Description of the bug:
What I noticed is that somehow the first 3 bytes of all files that are being read from the filesystem get truncated.
I'm almost certain that 1-2 weeks ago this bug wasn't there as I remember loading binary files (images) from the fs and this worked flawlessly. Now always 3 bytes are missing and the image does not get parsed.
I'm also not sure if this is even caused by esp-idf-sys.
My toolchain is the esp rust compiler version 1.57.0 targeting the default ESP32.
In the example I use the master branch of esp-idf, but I also encountered the issue in the stable 4.4 version.
Thanks!
EDIT:
When using a fixed size array instead of Vec or String to read in the file, it actually works! String::with_capacity on the other hand does not work.
The text was updated successfully, but these errors were encountered: