mirror of
https://github.com/curl/curl.git
synced 2026-08-04 01:10:00 +03:00
ftp: convert 'sock_accepted' to a plain boolean
This was an array indexed with sockindex but it was only ever used for the secondary socket. Closes #4929
This commit is contained in:
parent
03564deba2
commit
c188391a9f
3 changed files with 5 additions and 6 deletions
|
|
@ -1428,12 +1428,11 @@ int Curl_closesocket(struct connectdata *conn,
|
|||
curl_socket_t sock)
|
||||
{
|
||||
if(conn && conn->fclosesocket) {
|
||||
if((sock == conn->sock[SECONDARYSOCKET]) &&
|
||||
conn->sock_accepted[SECONDARYSOCKET])
|
||||
if((sock == conn->sock[SECONDARYSOCKET]) && conn->sock_accepted)
|
||||
/* if this socket matches the second socket, and that was created with
|
||||
accept, then we MUST NOT call the callback but clear the accepted
|
||||
status */
|
||||
conn->sock_accepted[SECONDARYSOCKET] = FALSE;
|
||||
conn->sock_accepted = FALSE;
|
||||
else {
|
||||
int rc;
|
||||
Curl_multi_closed(conn->data, sock);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue