servers: avoid unsafe calls in ctrl event, main wnd, wnd proc handlers (Windows)#22045
Draft
vszakats wants to merge 4 commits into
Draft
servers: avoid unsafe calls in ctrl event, main wnd, wnd proc handlers (Windows)#22045vszakats wants to merge 4 commits into
vszakats wants to merge 4 commits into
Conversation
Member
Author
|
and a broken fork/pipe, then hang: https://github.com/curl/curl/actions/runs/27620281150/job/81667049419?pr=22045 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
You can enable them for debugging purposes by uncommenting local macro
DEBUG_WIN32_CALLBACKS.Replace logging functionality with bare bones alternative using
WriteFile()andGetStdHandle()Win32 API calls only, replacing callsto CRT functions and internal APIs (that in turn call CRT functions.)
Not so much a bugfix, but an attempt to see if this patch makes any
difference with the long-time flaky CI test situation and/or avoid
potential issue with minimal loss of functionality. It's also easy for
the internal APIs accidentally picking up code that's not behaving well
in callbacks like these; another reason to avoid calling any.
Refs:
https://learn.microsoft.com/windows/console/registering-a-control-handler-function
https://learn.microsoft.com/windows/win32/api/winuser/nc-winuser-wndproc
https://learn.microsoft.com/previous-versions/windows/desktop/legacy/ms686736(v=vs.85)
Ref: 1c49f2f #18451