Fix winsock shutdown call
This commit is contained in:
parent
bf804d60a9
commit
7196e445ca
1 changed files with 2 additions and 1 deletions
3
tftp.c
3
tftp.c
|
|
@ -296,10 +296,11 @@ cleanup:
|
||||||
}
|
}
|
||||||
|
|
||||||
if (sock >= 0) {
|
if (sock >= 0) {
|
||||||
shutdown(sock, SHUT_RDWR);
|
|
||||||
#ifndef NMRPFLASH_WINDOWS
|
#ifndef NMRPFLASH_WINDOWS
|
||||||
|
shutdown(sock, SHUT_RDWR);
|
||||||
close(sock);
|
close(sock);
|
||||||
#else
|
#else
|
||||||
|
shutdown(sock, SD_BOTH);
|
||||||
closesocket(sock);
|
closesocket(sock);
|
||||||
#endif
|
#endif
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue