diff options
Diffstat (limited to 'networking/udhcp/packet.c')
-rw-r--r-- | networking/udhcp/packet.c | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/networking/udhcp/packet.c b/networking/udhcp/packet.c index 85910447b..dec9d0ab3 100644 --- a/networking/udhcp/packet.c +++ b/networking/udhcp/packet.c | |||
@@ -173,7 +173,6 @@ int udhcp_kernel_packet(struct dhcpMessage *payload, | |||
173 | uint32_t source_ip, int source_port, | 173 | uint32_t source_ip, int source_port, |
174 | uint32_t dest_ip, int dest_port) | 174 | uint32_t dest_ip, int dest_port) |
175 | { | 175 | { |
176 | int n = 1; | ||
177 | int fd, result; | 176 | int fd, result; |
178 | struct sockaddr_in client; | 177 | struct sockaddr_in client; |
179 | 178 | ||
@@ -181,7 +180,7 @@ int udhcp_kernel_packet(struct dhcpMessage *payload, | |||
181 | if (fd < 0) | 180 | if (fd < 0) |
182 | return -1; | 181 | return -1; |
183 | 182 | ||
184 | if (setsockopt(fd, SOL_SOCKET, SO_REUSEADDR, (char *) &n, sizeof(n)) == -1) { | 183 | if (setsockopt_reuseaddr(fd) == -1) { |
185 | close(fd); | 184 | close(fd); |
186 | return -1; | 185 | return -1; |
187 | } | 186 | } |