Fix the broken SO_REUSEADDR.
authorSteinar H. Gunderson <sgunderson@bigfoot.com>
Sat, 6 Apr 2013 19:11:12 +0000 (21:11 +0200)
committerSteinar H. Gunderson <sgunderson@bigfoot.com>
Sat, 6 Apr 2013 19:11:12 +0000 (21:11 +0200)
cubemap.cpp

index d0a3ac4..692d48b 100644 (file)
@@ -35,7 +35,7 @@ int create_server_socket(int port)
                exit(1);
        }
 
-       int one;        
+       int one = 1;
        if (setsockopt(server_sock, SOL_SOCKET, SO_REUSEADDR, &one, sizeof(one)) == -1) {
                perror("setsockopt(SO_REUSEADDR)");
                exit(1);