diff options
author | 2008-10-28 23:07:12 +0000 | |
---|---|---|
committer | 2008-10-28 23:07:12 +0000 | |
commit | c670bc113a8675fe9227099e09d006cf2ae4c457 (patch) | |
tree | 18e94cb2bfa3e07202766a73da1d0bd7c7e76653 | |
parent | fix missing n in error message (diff) | |
download | wireguard-openbsd-c670bc113a8675fe9227099e09d006cf2ae4c457.tar.xz wireguard-openbsd-c670bc113a8675fe9227099e09d006cf2ae4c457.zip |
Do not keep retrying to send advertisements if there is
no carpdev configured.
I don't see how we can run into this at all, but let's
leave this test for a a little extra safety.
OK henning@
-rw-r--r-- | sys/netinet/ip_carp.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/sys/netinet/ip_carp.c b/sys/netinet/ip_carp.c index bb61dd7d10f..228163fcf6c 100644 --- a/sys/netinet/ip_carp.c +++ b/sys/netinet/ip_carp.c @@ -1,4 +1,4 @@ -/* $OpenBSD: ip_carp.c,v 1.168 2008/09/03 08:37:51 mpf Exp $ */ +/* $OpenBSD: ip_carp.c,v 1.169 2008/10/28 23:07:12 mpf Exp $ */ /* * Copyright (c) 2002 Michael Shalayeff. All rights reserved. @@ -1088,13 +1088,13 @@ carp_send_ad(void *v) struct ifaddr *ifa; struct sockaddr sa; - s = splsoftnet(); - if (sc->sc_carpdev == NULL) { sc->sc_if.if_oerrors++; - goto retry_later; + return; } + s = splsoftnet(); + /* bow out if we've gone to backup (the carp interface is going down) */ if (sc->sc_bow_out) { advbase = 255; |