openbsd-ports/net/arpwatch/patches/patch-no_ip

22 lines
656 B
Plaintext
Raw Normal View History

$OpenBSD: patch-no_ip,v 1.3 2001/06/01 23:36:32 jakob Exp $
Do not bail if the interface does not have an IP assigned.
--- arpwatch.c.orig Sat Oct 14 04:07:35 2000
+++ arpwatch.c Sat Jun 2 01:22:14 2001
@@ -223,9 +223,11 @@ main(int argc, char **argv)
/* Determine network and netmask */
if (pcap_lookupnet(interface, &net, &netmask, errbuf) < 0) {
- (void)fprintf(stderr, "%s: bad interface %s: %s\n",
- prog, interface, errbuf);
- exit(1);
+ (void)fprintf(stderr,
+ "%s: WARNING: cannot determine net/mask: %s\n",
+ prog, errbuf);
+ net = 0;
+ netmask = 0;
}
/* Drop into the background if not debugging */