diff options
Diffstat (limited to '')
-rw-r--r-- | networking/httpd.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/networking/httpd.c b/networking/httpd.c index 452b56d19..64d88f1cd 100644 --- a/networking/httpd.c +++ b/networking/httpd.c | |||
@@ -863,6 +863,7 @@ static int openServer(void) | |||
863 | { | 863 | { |
864 | struct sockaddr_in lsocket; | 864 | struct sockaddr_in lsocket; |
865 | int fd; | 865 | int fd; |
866 | int on = 1; | ||
866 | 867 | ||
867 | /* create the socket right now */ | 868 | /* create the socket right now */ |
868 | /* inet_addr() returns a value that is already in network order */ | 869 | /* inet_addr() returns a value that is already in network order */ |
@@ -873,7 +874,6 @@ static int openServer(void) | |||
873 | fd = bb_xsocket(AF_INET, SOCK_STREAM, 0); | 874 | fd = bb_xsocket(AF_INET, SOCK_STREAM, 0); |
874 | /* tell the OS it's OK to reuse a previous address even though */ | 875 | /* tell the OS it's OK to reuse a previous address even though */ |
875 | /* it may still be in a close down state. Allows bind to succeed. */ | 876 | /* it may still be in a close down state. Allows bind to succeed. */ |
876 | int on = 1; | ||
877 | #ifdef SO_REUSEPORT | 877 | #ifdef SO_REUSEPORT |
878 | setsockopt(fd, SOL_SOCKET, SO_REUSEPORT, (void *)&on, sizeof(on)) ; | 878 | setsockopt(fd, SOL_SOCKET, SO_REUSEPORT, (void *)&on, sizeof(on)) ; |
879 | #else | 879 | #else |