[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[GNUnet-SVN] r12665 - gnunet/src/transport
From: |
gnunet |
Subject: |
[GNUnet-SVN] r12665 - gnunet/src/transport |
Date: |
Thu, 19 Aug 2010 11:51:41 +0200 |
Author: nevans
Date: 2010-08-19 11:51:41 +0200 (Thu, 19 Aug 2010)
New Revision: 12665
Modified:
gnunet/src/transport/gnunet-nat-server-windows.c
Log:
workingish?
Modified: gnunet/src/transport/gnunet-nat-server-windows.c
===================================================================
--- gnunet/src/transport/gnunet-nat-server-windows.c 2010-08-19 09:50:16 UTC
(rev 12664)
+++ gnunet/src/transport/gnunet-nat-server-windows.c 2010-08-19 09:51:41 UTC
(rev 12665)
@@ -341,8 +341,6 @@
static Socket
make_raw_socket ()
{
- const int one = 1;
-
DWORD bOptVal = TRUE;
int bOptLen = sizeof(bOptVal);
@@ -354,22 +352,12 @@
strerror (errno));
return -1;
}
+
if (setsockopt(rawsock, SOL_SOCKET, SO_BROADCAST, (char*)&bOptVal, bOptLen)
== 0)
- {
- fprintf(stderr, "Set SO_BROADCAST: ON\n");
- }
- else
- {
fprintf(stderr, "Error setting SO_BROADCAST: ON\n");
- }
- if (setsockopt(rawsock, IPPROTO_IP, IP_HDRINCL, (char*)&bOptVal, bOptLen) ==
0)
- {
- fprintf(stderr, "Set IP_HDRINCL: ON\n");
- }
- else
- {
+
+ if (setsockopt(rawsock, IPPROTO_IP, IP_HDRINCL, (char*)&bOptVal, bOptLen) !=
0)
fprintf(stderr, "Error setting IP_HDRINCL: ON\n");
- }
return rawsock;
}
@@ -383,7 +371,7 @@
// WSA startup
WSADATA wsaData;
- if (WSAStartup (MAKEWORD (2, 2), &wsaData) != 0)
+ if (WSAStartup (MAKEWORD (2, 1), &wsaData) != 0)
{
fprintf (stderr, "Failed to find Winsock 2.1 or better.\n");
return 4; // ERROR
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [GNUnet-SVN] r12665 - gnunet/src/transport,
gnunet <=