Do this the Right Way (tm), i.e. use shutdown() instead of fooling around

with the size of the receive buffer.

Pointed out by:	ru
This commit is contained in:
des 2000-01-14 15:37:18 +00:00
parent cb9a455cbe
commit 4e26c2b9bd

View File

@ -418,12 +418,8 @@ main(argc, argv)
}
}
if (finet >= 0 && SecureMode) {
int bufsize;
bufsize = 1;
if (setsockopt(finet, SOL_SOCKET, SO_RCVBUF,
&bufsize, sizeof bufsize) < 0) {
logerror("setsockopt");
if (shutdown(finet, SHUT_RD) < 0) {
logerror("shutdown");
if (!Debug)
die(0);
}