Skip to content
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

Midi is corrupted error when char is unsigned #334

Open
felipemanga opened this issue Mar 13, 2023 · 1 comment
Open

Midi is corrupted error when char is unsigned #334

felipemanga opened this issue Mar 13, 2023 · 1 comment

Comments

@felipemanga
Copy link

The following line (MidiTrack.cpp, line 236) assumes char is signed:
keySig = static_cast<char>(readByte()); // force sign conversion ...
This fails on platforms where it isn't.
A potential fix is:
keySig = static_cast<signed char>(readByte());

@Martchus
Copy link
Contributor

I suggest you create a PR. Since this project isn't maintained very actively it may take a while until it gets merged, though.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants