rust-windowing / rust-windowing/winit
Potentially invalid message dispatched on Windows
Nobody has claimed this yet.
- Dominant language
- Rust
- Stars
- 6.2k
- Forks
- 1.3k
- Avg merge
- 2d 19h
- Merged PRs (30d)
- 9
Description
The documentation of GetMessage on windows states that the return value is -1 in case of an error. This error is not handled by the library:
Possible solutions are using <= 0 (to include -1) or handling it seperately. It seems that platform_imp::windows::event_loop::run_return provides no feedback on possible errors.
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start at src/platform_impl/windows/event_loop.rs around line 259 and inspect how GetMessage is handled in the Windows event loop, including platform_imp::windows::event_loop::run_return. Compare that behavior with the documented -1 error return and determine how the library should report it; done means the error case is handled without changing normal event dispatch.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- rust
- Domain
- desktop, operating-systems
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100