summaryrefslogtreecommitdiff
path: root/networking/udhcp/dhcprelay.c
diff options
context:
space:
mode:
authorDenis Vlasenko2008-01-25 22:46:34 +0000
committerDenis Vlasenko2008-01-25 22:46:34 +0000
commitb76b9a4328460fdee7d72c08a89d1d79392beb99 (patch)
tree9346e038153ee2646e1f036ed6310b97cac5923d /networking/udhcp/dhcprelay.c
parent893988182a97bc58d8d1d8eb15d00e427801cedd (diff)
downloadbusybox-b76b9a4328460fdee7d72c08a89d1d79392beb99.zip
busybox-b76b9a4328460fdee7d72c08a89d1d79392beb99.tar.gz
udhcpc: filter unwanted packets in kernel
(Cristian Ionescu-Idbohrn <cristian.ionescu-idbohrn@axis.com>)
Diffstat (limited to 'networking/udhcp/dhcprelay.c')
-rw-r--r--networking/udhcp/dhcprelay.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/networking/udhcp/dhcprelay.c b/networking/udhcp/dhcprelay.c
index a6483fc..c243cc1 100644
--- a/networking/udhcp/dhcprelay.c
+++ b/networking/udhcp/dhcprelay.c
@@ -155,12 +155,12 @@ static int init_sockets(char **client, int num_clients,
int i, n;
/* talk to real server on bootps */
- fds[0] = listen_socket(/*INADDR_ANY,*/ 67, server);
+ fds[0] = listen_socket(/*INADDR_ANY,*/ SERVER_PORT, server);
n = fds[0];
for (i = 1; i < num_clients; i++) {
/* listen for clients on bootps */
- fds[i] = listen_socket(/*INADDR_ANY,*/ 67, client[i-1]);
+ fds[i] = listen_socket(/*INADDR_ANY,*/ SERVER_PORT, client[i-1]);
if (fds[i] > n)
n = fds[i];
}
@@ -289,7 +289,7 @@ int dhcprelay_main(int argc, char **argv)
struct sockaddr_in server_addr;
server_addr.sin_family = AF_INET;
- server_addr.sin_port = htons(67);
+ server_addr.sin_port = htons(SERVER_PORT);
if (argc == 4) {
if (!inet_aton(argv[3], &server_addr.sin_addr))
bb_perror_msg_and_die("didn't grok server");