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

Port fix for rust-windowing/winit/issues/2291 #14

Open
wants to merge 2 commits into
base: v0.28.6
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,8 @@ And please only add new entries to the top of this list, right below the `# Unre

# Unreleased

- On Windows, fix re-entrant event loop crash from rust-windowing/winit/issues/2291

# 0.28.6

- On macOS, fixed memory leak when getting monitor handle.
Expand Down
4 changes: 3 additions & 1 deletion src/platform_impl/windows/event_loop.rs
Original file line number Diff line number Diff line change
Expand Up @@ -2538,7 +2538,9 @@ unsafe extern "system" fn thread_event_target_callback<T: 'static>(
}
}
}
userdata.event_loop_runner.poll();
if !userdata.event_loop_runner.should_buffer() {
userdata.event_loop_runner.poll();
}
0
}
_ => DefWindowProcW(window, msg, wparam, lparam),
Expand Down