Remove unused variable
This commit is contained in:
parent
1b022a0d05
commit
38fe65f8bd
1 changed files with 5 additions and 4 deletions
|
|
@ -252,7 +252,6 @@ int setSocketNonBlocking(SOCKET s, int val) {
|
||||||
|
|
||||||
SOCKET createSocket(int addressFamily, int socketType, int protocol, int nonBlocking) {
|
SOCKET createSocket(int addressFamily, int socketType, int protocol, int nonBlocking) {
|
||||||
SOCKET s;
|
SOCKET s;
|
||||||
int val;
|
|
||||||
|
|
||||||
s = socket(addressFamily, socketType, protocol);
|
s = socket(addressFamily, socketType, protocol);
|
||||||
if (s == INVALID_SOCKET) {
|
if (s == INVALID_SOCKET) {
|
||||||
|
|
@ -261,9 +260,11 @@ SOCKET createSocket(int addressFamily, int socketType, int protocol, int nonBloc
|
||||||
}
|
}
|
||||||
|
|
||||||
#ifdef LC_DARWIN
|
#ifdef LC_DARWIN
|
||||||
// Disable SIGPIPE on iOS
|
{
|
||||||
val = 1;
|
// Disable SIGPIPE on iOS
|
||||||
setsockopt(s, SOL_SOCKET, SO_NOSIGPIPE, (char*)&val, sizeof(val));
|
int val = 1;
|
||||||
|
setsockopt(s, SOL_SOCKET, SO_NOSIGPIPE, (char*)&val, sizeof(val));
|
||||||
|
}
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
if (nonBlocking) {
|
if (nonBlocking) {
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue