svn commit: trunk/busybox/networking
vda at busybox.net
vda at busybox.net
Sun Nov 25 12:53:28 UTC 2007
Author: vda
Date: 2007-11-25 04:53:25 -0800 (Sun, 25 Nov 2007)
New Revision: 20532
Log:
zcip: simplify code a bit
Modified:
trunk/busybox/networking/zcip.c
Changeset:
Modified: trunk/busybox/networking/zcip.c
===================================================================
--- trunk/busybox/networking/zcip.c 2007-11-25 12:40:56 UTC (rev 20531)
+++ trunk/busybox/networking/zcip.c 2007-11-25 12:53:25 UTC (rev 20532)
@@ -177,7 +177,6 @@
{
int state = PROBE;
struct ether_addr eth_addr;
- const char *why;
char *r_opt;
unsigned opts;
@@ -319,8 +318,6 @@
VDBG("...wait %d %s nprobes=%u, nclaims=%u\n",
timeout_ms, intf, nprobes, nclaims);
- // FIXME: do we really receive ALL packets here??
- // if yes, set up filtering to get ARPs only!!! (see arping)
switch (safe_poll(fds, 1, timeout_ms)) {
default:
@@ -447,8 +444,7 @@
// read ARP packet
if (safe_read(sock_fd, &p, sizeof(p)) < 0) {
- why = "recv";
- goto bad;
+ bb_perror_msg_and_die(bb_msg_read_error);
}
if (p.eth.ether_type != htons(ETHERTYPE_ARP))
continue;
@@ -550,7 +546,4 @@
break; // case 1 (packets arriving)
} // switch poll
} // while (1)
- bad:
- bb_perror_msg("%s: %s", intf, why);
- return EXIT_FAILURE;
}
More information about the busybox-cvs
mailing list