michael@714: --- arpd.c.dist 2003-07-02 16:49:31.000000000 +0200 michael@714: +++ arpd.c 2003-07-02 16:53:25.000000000 +0200 michael@714: @@ -111,9 +111,11 @@ michael@714: struct in_addr in; michael@714: ip_addr_t istart, iend; michael@714: michael@714: - second = p; michael@714: + first = p; michael@714: + second = strchr(p, '-'); michael@714: + if (second != NULL) michael@714: + *second++ = '\0'; michael@714: michael@714: - first = strsep(&second, "-"); michael@714: if (second == NULL) michael@714: errx(1, "%s: Invalid network range: %s", michael@714: __func__, p); michael@714: @@ -267,7 +267,7 @@ michael@714: spa->addr_ip, tha->addr_eth, tpa->addr_ip); michael@714: michael@714: if (op == ARP_OP_REQUEST) { michael@714: - syslog(LOG_DEBUG, __FUNCTION__ ": who-has %s tell %s", michael@714: + syslog(LOG_DEBUG, "%s: who-has %s tell %s", __FUNCTION__, michael@714: addr_ntoa(tpa), addr_ntoa(spa)); michael@714: } else if (op == ARP_OP_REPLY) { michael@714: syslog(LOG_INFO, "arp reply %s is-at %s", michael@714: @@ -284,7 +284,7 @@ michael@714: int error; michael@714: michael@714: if (addr_cmp(addr, &arpd_ifent.intf_addr) == 0) { michael@714: - syslog(LOG_DEBUG, __FUNCTION__ ": %s at %s", michael@714: + syslog(LOG_DEBUG, "%s: %s at %s", __FUNCTION__, michael@714: addr_ntoa(addr), addr_ntoa(&arpd_ifent.intf_link_addr)); michael@714: return (0); michael@714: } michael@714: @@ -293,10 +293,10 @@ michael@714: error = arp_get(arpd_arp, &arpent); michael@714: michael@714: if (error == -1) { michael@714: - syslog(LOG_DEBUG, __FUNCTION__ ": no entry for %s", michael@714: + syslog(LOG_DEBUG, "%s: no entry for %s", __FUNCTION__, michael@714: addr_ntoa(addr)); michael@714: } else { michael@714: - syslog(LOG_DEBUG, __FUNCTION__ ": %s at %s", michael@714: + syslog(LOG_DEBUG, "%s: %s at %s", __FUNCTION__, michael@714: addr_ntoa(addr), addr_ntoa(&arpent.arp_ha)); michael@714: } michael@714: return (error); michael@714: @@ -425,7 +425,7 @@ michael@714: if ((req = SPLAY_FIND(tree, &arpd_reqs, &tmp)) != NULL) { michael@714: addr_pack(&src.arp_ha, ADDR_TYPE_ETH, ETH_ADDR_BITS, michael@714: ethip->ar_sha, ETH_ADDR_LEN); michael@714: - syslog(LOG_DEBUG, __FUNCTION__ ": %s at %s", michael@714: + syslog(LOG_DEBUG, "%s: %s at %s", __FUNCTION__, michael@714: addr_ntoa(&req->pa), addr_ntoa(&src.arp_ha)); michael@714: michael@714: /* This address is claimed */