aboutsummaryrefslogtreecommitdiff
path: root/networking/udhcp/socket.c
diff options
context:
space:
mode:
Diffstat (limited to 'networking/udhcp/socket.c')
-rw-r--r--networking/udhcp/socket.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/networking/udhcp/socket.c b/networking/udhcp/socket.c
index de494ca38..6b15766c9 100644
--- a/networking/udhcp/socket.c
+++ b/networking/udhcp/socket.c
@@ -57,7 +57,7 @@ int FAST_FUNC udhcp_read_interface(const char *interface, int *ifindex, uint32_t
57 } 57 }
58 our_ip = (struct sockaddr_in *) &ifr.ifr_addr; 58 our_ip = (struct sockaddr_in *) &ifr.ifr_addr;
59 *nip = our_ip->sin_addr.s_addr; 59 *nip = our_ip->sin_addr.s_addr;
60 DEBUG("ip of %s = %s", interface, inet_ntoa(our_ip->sin_addr)); 60 log1("IP %s", inet_ntoa(our_ip->sin_addr));
61 } 61 }
62 62
63 if (ifindex) { 63 if (ifindex) {
@@ -65,7 +65,7 @@ int FAST_FUNC udhcp_read_interface(const char *interface, int *ifindex, uint32_t
65 close(fd); 65 close(fd);
66 return -1; 66 return -1;
67 } 67 }
68 DEBUG("adapter index %d", ifr.ifr_ifindex); 68 log1("Adapter index %d", ifr.ifr_ifindex);
69 *ifindex = ifr.ifr_ifindex; 69 *ifindex = ifr.ifr_ifindex;
70 } 70 }
71 71
@@ -75,7 +75,7 @@ int FAST_FUNC udhcp_read_interface(const char *interface, int *ifindex, uint32_t
75 return -1; 75 return -1;
76 } 76 }
77 memcpy(mac, ifr.ifr_hwaddr.sa_data, 6); 77 memcpy(mac, ifr.ifr_hwaddr.sa_data, 6);
78 DEBUG("adapter hardware address %02x:%02x:%02x:%02x:%02x:%02x", 78 log1("MAC %02x:%02x:%02x:%02x:%02x:%02x",
79 mac[0], mac[1], mac[2], mac[3], mac[4], mac[5]); 79 mac[0], mac[1], mac[2], mac[3], mac[4], mac[5]);
80 } 80 }
81 81
@@ -90,7 +90,7 @@ int FAST_FUNC udhcp_listen_socket(/*uint32_t ip,*/ int port, const char *inf)
90 int fd; 90 int fd;
91 struct sockaddr_in addr; 91 struct sockaddr_in addr;
92 92
93 DEBUG("Opening listen socket on *:%d %s", port, inf); 93 log1("Opening listen socket on *:%d %s", port, inf);
94 fd = xsocket(PF_INET, SOCK_DGRAM, IPPROTO_UDP); 94 fd = xsocket(PF_INET, SOCK_DGRAM, IPPROTO_UDP);
95 95
96 setsockopt_reuseaddr(fd); 96 setsockopt_reuseaddr(fd);