-
-
Notifications
You must be signed in to change notification settings - Fork 1k
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
Fix JACK MIDI dropping events when two events have the same time stamp. #5994
Conversation
🤖 Hey, I'm @LmmsBot from github.com/lmms/bot and I made downloads for this pull request, click me to make them magically appear! 🎩
Windows
Linux
macOS🤖{"platform_name_to_artifacts": {"Windows": [{"artifact": {"title": {"title": "32-bit", "platform_name": "Windows"}, "link": {"link": "https://13624-15778896-gh.circle-artifacts.com/0/lmms-1.3.0-alpha.1.102%2Bgaa4989bc5-mingw-win32.exe"}}, "build_link": "https://circleci.com/gh/LMMS/lmms/13624?utm_campaign=vcs-integration-link&utm_medium=referral&utm_source=github-build-link"}, {"artifact": {"title": {"title": "64-bit", "platform_name": "Windows"}, "link": {"link": "https://13622-15778896-gh.circle-artifacts.com/0/lmms-1.3.0-alpha.1.102%2Bgaa4989bc5-mingw-win64.exe"}}, "build_link": "https://circleci.com/gh/LMMS/lmms/13622?utm_campaign=vcs-integration-link&utm_medium=referral&utm_source=github-build-link"}, {"artifact": {"title": {"title": "32-bit", "platform_name": "Windows"}, "link": {"link": "https://ci.appveyor.com/api/buildjobs/bnqfbpfih3e514ec/artifacts/build/lmms-1.3.0-alpha-msvc2017-win32.exe"}}, "build_link": "https://ci.appveyor.com/project/Lukas-W/lmms/builds/38829668"}, {"artifact": {"title": {"title": "64-bit", "platform_name": "Windows"}, "link": {"link": "https://ci.appveyor.com/api/buildjobs/1ywheurvis0ep3si/artifacts/build/lmms-1.3.0-alpha-msvc2017-win64.exe"}}, "build_link": "https://ci.appveyor.com/project/Lukas-W/lmms/builds/38829668"}], "Linux": [{"artifact": {"title": {"title": "(AppImage)", "platform_name": "Linux"}, "link": {"link": "https://13621-15778896-gh.circle-artifacts.com/0/lmms-1.3.0-alpha.1.102%2Bgaa4989b-linux-x86_64.AppImage"}}, "build_link": "https://circleci.com/gh/LMMS/lmms/13621?utm_campaign=vcs-integration-link&utm_medium=referral&utm_source=github-build-link"}], "macOS": [{"artifact": {"title": {"title": "", "platform_name": "macOS"}, "link": {"link": "https://13625-15778896-gh.circle-artifacts.com/0/lmms-1.3.0-alpha.1.102%2Bgaa4989bc5-mac10.14.dmg"}}, "build_link": "https://circleci.com/gh/LMMS/lmms/13625?utm_campaign=vcs-integration-link&utm_medium=referral&utm_source=github-build-link"}]}, "commit_sha": "cd68ced1db07d94e59a169614fe364437ccdbdbc"} |
As the person reporting the bug, I cannot reproduce it on this version |
@JohannesLorenz you're the previous committer for this loop fixing another bug, so pinging you for attention (would hate to regress). I see no issue changing |
Looking at the function around the fix, I wonder if it could be straightened into a |
Tangential topic: I did some looking around, it's possible we may have another bug in this loop related to SysEx messages. |
|
Sorry, I missed this, but it looks basically good 👍 |
As reported and debugged on Discord: JACK MIDI input has a tendency to drop events.
Explanation:
jack_midi_event_get
is called to get a new event at the end of the for loop, ifin_event_time == i
i
gets incremented for the next iteration.time
as the previous one, the comparison will be false and remain so for the rest of the buffer. Any further events will be ignored.I suggest turning the
if
into awhile
to handle all events with the sametime
value.