diff options
author | Kenneth R Westerback <krw@cvs.openbsd.org> | 2014-05-12 13:12:42 +0000 |
---|---|---|
committer | Kenneth R Westerback <krw@cvs.openbsd.org> | 2014-05-12 13:12:42 +0000 |
commit | 54fb3f5f03f76a9e19d1b67c88adac23f5b576ad (patch) | |
tree | 2888a66dfd00888cbc49af3d9b12ff6e5ae516cc /sbin/dhclient | |
parent | 40e5ba0182d32d492e40b3b2b4ddec869e7b6739 (diff) |
Since all static leases are in one file, /etc/dhclient.conf, there is no
'wrong interface' specification. So display that error message only for
non-static leases. i.e. when reading /var/db/dhclient.leases.<if>.
Diffstat (limited to 'sbin/dhclient')
-rw-r--r-- | sbin/dhclient/clparse.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/sbin/dhclient/clparse.c b/sbin/dhclient/clparse.c index ebbda2c0c25..b5f06fb5401 100644 --- a/sbin/dhclient/clparse.c +++ b/sbin/dhclient/clparse.c @@ -1,4 +1,4 @@ -/* $OpenBSD: clparse.c,v 1.86 2014/05/11 12:40:37 krw Exp $ */ +/* $OpenBSD: clparse.c,v 1.87 2014/05/12 13:12:41 krw Exp $ */ /* Parser for dhclient config and lease files. */ @@ -536,7 +536,8 @@ parse_client_lease_declaration(FILE *cfile, struct client_lease *lease) return; } if (strcmp(ifi->name, val) != 0) { - parse_warn("wrong interface name."); + if (lease->is_static == 0) + parse_warn("wrong interface name."); skip_to_semi(cfile); return; } |