krb5: fix socket confusion, MSVC compiler warnings #15585
Closed
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.
fix socket/sockindex confusion on writes:
The callstack used to end with
Curl_write_plain()
accepting a sockettill 7.87.0. This call got swapped for
Curl_conn_send()
, expectinga sockindex.
socket_write()
was updated accordingly. Its callersmissed it and continued operating on sockets:
do_sec_send()
,sec_write()
, passing it down the stack andCurl_conn_send()
resolving it as if it was a sockindex.
It affected FTP Kerberos authentication.
Discovered through MSVC warnings:
Ref: https://github.com/curl/curl/actions/runs/11846599621/job/33014592805#step:9:32
Follow-up to 5651a36 Conn_recv/send_plain refactoring, USE_RECV_BEFORE_SEND_WORKAROUND in cf-socket #10280
Bug: GHA/windows: add gssapi to openssl job #15549 (comment)
Fixes int/socket confusion warnings #15582
fix uninitialized buffer:
Ref: https://github.com/curl/curl/actions/runs/11848626645/job/33020501026?pr=15585#step:9:31
silence unreachable code compiler warning:
Ref: https://github.com/curl/curl/actions/runs/11848626645/job/33020501026?pr=15585#step:9:30