@@ -501,11 +501,12 @@ @throw [OFBindFailedException exceptionWithClass: [self class] socket: self host: host port: port]; - if (setsockopt(sock, SOL_SOCKET, SO_REUSEADDR, &one, sizeof(one))) + if (setsockopt(sock, SOL_SOCKET, SO_REUSEADDR, (const char*)&one, + sizeof(one))) @throw [OFSetOptionFailedException exceptionWithClass: [self class] stream: self]; if (bind(sock, res->ai_addr, res->ai_addrlen) == -1) { @@ -560,11 +561,12 @@ @throw [OFBindFailedException exceptionWithClass: [self class] socket: self host: host port: port]; - if (setsockopt(sock, SOL_SOCKET, SO_REUSEADDR, &one, sizeof(one))) + if (setsockopt(sock, SOL_SOCKET, SO_REUSEADDR, (const char*)&one, + sizeof(one))) @throw [OFSetOptionFailedException exceptionWithClass: [self class] stream: self]; if (bind(sock, (struct sockaddr*)&addr.in, sizeof(addr.in)) == -1) {