aboutsummaryrefslogtreecommitdiff
path: root/networking/udhcp/common.h
diff options
context:
space:
mode:
authorDenis Vlasenko <vda.linux@googlemail.com>2008-01-25 22:46:34 +0000
committerDenis Vlasenko <vda.linux@googlemail.com>2008-01-25 22:46:34 +0000
commitb76b9a4328460fdee7d72c08a89d1d79392beb99 (patch)
tree9346e038153ee2646e1f036ed6310b97cac5923d /networking/udhcp/common.h
parent893988182a97bc58d8d1d8eb15d00e427801cedd (diff)
downloadbusybox-b76b9a4328460fdee7d72c08a89d1d79392beb99.tar.gz
udhcpc: filter unwanted packets in kernel
(Cristian Ionescu-Idbohrn <cristian.ionescu-idbohrn@axis.com>)
Diffstat (limited to 'networking/udhcp/common.h')
-rw-r--r--networking/udhcp/common.h7
1 files changed, 5 insertions, 2 deletions
diff --git a/networking/udhcp/common.h b/networking/udhcp/common.h
index 38ede0124..b1d629b18 100644
--- a/networking/udhcp/common.h
+++ b/networking/udhcp/common.h
@@ -14,6 +14,9 @@
#define DEFAULT_SCRIPT "/usr/share/udhcpc/default.script"
+#define SERVER_PORT 67
+#define CLIENT_PORT 68
+
extern const uint8_t MAC_BCAST_ADDR[6]; /* six all-ones */
/*** packet.h ***/
@@ -21,7 +24,7 @@ extern const uint8_t MAC_BCAST_ADDR[6]; /* six all-ones */
#include <netinet/udp.h>
#include <netinet/ip.h>
-#define DHCP_OPTIONS_BUFSIZE 308
+#define DHCP_OPTIONS_BUFSIZE 308
struct dhcpMessage {
uint8_t op;
@@ -93,7 +96,7 @@ int listen_socket(/*uint32_t ip,*/ int port, const char *inf);
int arpping(uint32_t test_ip, uint32_t from_ip, uint8_t *from_mac, const char *interface);
#if ENABLE_FEATURE_UDHCP_DEBUG
-# define DEBUG(str, args...) bb_info_msg(str, ## args)
+# define DEBUG(str, args...) bb_info_msg("### " str, ## args)
#else
# define DEBUG(str, args...) do {;} while (0)
#endif