diff options
author | Alexander Bluhm <bluhm@cvs.openbsd.org> | 2010-12-13 13:43:38 +0000 |
---|---|---|
committer | Alexander Bluhm <bluhm@cvs.openbsd.org> | 2010-12-13 13:43:38 +0000 |
commit | b0df33e6be664a058d2ab847721047a6d38aeefb (patch) | |
tree | 5d237ba99b4aef1d846ab5cba7afb7ff3205a1f3 /usr.sbin/ospf6d | |
parent | 6f34bebf1bae9862f0956f8da54378c6d095eb20 (diff) |
Do not use a carp address as ospf router id because it is not unique.
ok claudio@
Diffstat (limited to 'usr.sbin/ospf6d')
-rw-r--r-- | usr.sbin/ospf6d/parse.y | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/usr.sbin/ospf6d/parse.y b/usr.sbin/ospf6d/parse.y index f1cca75a3db..7afae43a814 100644 --- a/usr.sbin/ospf6d/parse.y +++ b/usr.sbin/ospf6d/parse.y @@ -1,4 +1,4 @@ -/* $OpenBSD: parse.y,v 1.19 2010/08/22 21:15:25 bluhm Exp $ */ +/* $OpenBSD: parse.y,v 1.20 2010/12/13 13:43:37 bluhm Exp $ */ /* * Copyright (c) 2004, 2005 Esben Norby <norby@openbsd.org> @@ -1042,6 +1042,8 @@ get_rtr_id(void) fatal("getifaddrs"); for (ifa = ifap; ifa; ifa = ifa->ifa_next) { + if (strncmp(ifa->ifa_name, "carp", 4) == 0) + continue; if (ifa->ifa_addr->sa_family != AF_INET) continue; cur = ((struct sockaddr_in *)ifa->ifa_addr)->sin_addr.s_addr; |