mirror of
https://github.com/gnustep/libs-base.git
synced 2025-04-23 00:41:02 +00:00
tweak to keep checker happy
This commit is contained in:
parent
f1b1c1c754
commit
78087d0aa4
2 changed files with 15 additions and 2 deletions
|
@ -1,3 +1,8 @@
|
|||
2018-01-27 Richard Frith-Macdonald <rfm@gnu.org>
|
||||
|
||||
* Source/GSFileHandle.m: keep checker happy by usingn return value of
|
||||
setsockopt.
|
||||
|
||||
2018-01-26 Richard Frith-Macdonald <rfm@gnu.org>
|
||||
|
||||
* Source/GSFTPURLHandle.m: change memcpy to memmove to avoid possible
|
||||
|
|
|
@ -205,7 +205,11 @@ static int tuneSBuf = 0;
|
|||
* Enable tcp-level tracking of whether connection is alive.
|
||||
*/
|
||||
value = 1;
|
||||
setsockopt(desc, SOL_SOCKET, SO_KEEPALIVE, (char *)&value, sizeof(value));
|
||||
if (setsockopt(desc, SOL_SOCKET, SO_KEEPALIVE, (char *)&value, sizeof(value))
|
||||
< 0)
|
||||
{
|
||||
NSDebugMLLog(@"GSTcpTune", @"setsockopt keepalive failed");
|
||||
}
|
||||
|
||||
if (tuneLinger >= 0)
|
||||
{
|
||||
|
@ -1016,7 +1020,11 @@ NSString * const GSSOCKSRecvAddr = @"GSSOCKSRecvAddr";
|
|||
* that multiple processes can serve the same port simultaneously.
|
||||
* We don't want that broken behavior!
|
||||
*/
|
||||
setsockopt(net, SOL_SOCKET, SO_REUSEADDR, (char *)&status, sizeof(status));
|
||||
if (setsockopt(net, SOL_SOCKET, SO_REUSEADDR, (char*)&status, sizeof(status))
|
||||
< 0)
|
||||
{
|
||||
NSDebugMLLog(@"GSTcpTune", @"setsockopt reuseaddr failed");
|
||||
}
|
||||
#endif
|
||||
|
||||
if (bind(net, &sin, GSPrivateSockaddrLength(&sin)) == -1)
|
||||
|
|
Loading…
Reference in a new issue