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

system.h: sync mingw CURL_TYPEOF_CURL_SOCKLEN_T with other compilers #12501

Closed
wants to merge 2 commits into from

Conversation

vszakats
Copy link
Member

@vszakats vszakats commented Dec 11, 2023

Align mingw with the other Windows compilers and use the int type for
CURL_TYPEOF_CURL_SOCKLEN_T (and thus for curl_socklent_t). This
makes it unnecessary to make a mingw-specific trick and pull all Windows
headers early just for this type definition. This type is specific to
Windows, not to the compiler. mingw-w64's Windows header maps it to
int too.

With this we also delete all remaining uses of CURL_PULL_WS2TCPIP_H.

[ The official solution is to use socklen_t for all Windows compilers.
In this case we may want to update curl/curl.h to pull in Windows
headers before system.h. ]

Closes #12501

Align mingw with the other Windows compilers and use the `int` type for
`CURL_TYPEOF_CURL_SOCKLEN_T` (and thus for `curl_socklent_t`). This
makes it unnecessary to make a mingw-specific trick and pull all Windows
headers early just for this type definition. This type is specific to
Windows, not to the compiler. mingw-w64's Windows header maps it to
`int` too.

With this we also delete all remaining uses of `CURL_PULL_WS2TCPIP_H`.

[ The official solution is to use `socklen_t` for all Windows compilers.
In this case we may want to update `curl/curl.h` to pull in Windows
headers before `system.h`. ]

Closes #xxxxx
@vszakats vszakats added the Windows Windows-specific label Dec 11, 2023
@vszakats vszakats closed this in 6265718 Dec 16, 2023
@vszakats vszakats deleted the mingw-socklen branch December 16, 2023 13:19
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
libcurl API Windows Windows-specific
Development

Successfully merging this pull request may close these issues.

None yet

3 participants