Created
June 9, 2011 18:23
-
-
Save benthor/1017374 to your computer and use it in GitHub Desktop.
proper freebsd support for djb's nacl-20110221
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Only in nacl-20110221-patched: build | |
| diff -aur nacl-20110221/curvecp/socket_bind.c nacl-20110221-patched/curvecp/socket_bind.c | |
| --- nacl-20110221/curvecp/socket_bind.c 2011-02-21 01:49:34.000000000 +0000 | |
| +++ nacl-20110221-patched/curvecp/socket_bind.c 2011-06-09 16:50:33.000000000 +0000 | |
| @@ -9,6 +9,7 @@ | |
| { | |
| struct sockaddr_in sa; | |
| byte_zero(&sa,sizeof sa); | |
| + sa.sin_family = PF_INET; | |
| byte_copy(&sa.sin_addr,4,ip); | |
| byte_copy(&sa.sin_port,2,port); | |
| return bind(fd,(struct sockaddr *) &sa,sizeof sa); | |
| diff -aur nacl-20110221/curvecp/socket_udp.c nacl-20110221-patched/curvecp/socket_udp.c | |
| --- nacl-20110221/curvecp/socket_udp.c 2011-02-21 01:49:34.000000000 +0000 | |
| +++ nacl-20110221-patched/curvecp/socket_udp.c 2011-06-09 16:50:18.000000000 +0000 | |
| @@ -6,6 +6,10 @@ | |
| #include "socket.h" | |
| #include "blocking.h" | |
| +#ifndef SOL_IP | |
| +#define SOL_IP IPPROTO_IP | |
| +#endif | |
| + | |
| static void enable_bsd_fragmentation(int fd) | |
| { | |
| #ifdef IP_DONTFRAG |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment