diff options
author | 2005-06-07 05:10:57 +0000 | |
---|---|---|
committer | 2005-06-07 05:10:57 +0000 | |
commit | eb95ae85f3c77b8794345c5510db3ee00bc7b20f (patch) | |
tree | 9aee041553a10d8154feb796779ff2ca64a43ce6 | |
parent | Don't restrict what login name may be removed, the account may (diff) | |
download | wireguard-openbsd-eb95ae85f3c77b8794345c5510db3ee00bc7b20f.tar.xz wireguard-openbsd-eb95ae85f3c77b8794345c5510db3ee00bc7b20f.zip |
fix a possible panic in error path,
do not try to check debug status of a
non existing interface in server mode.
-rw-r--r-- | sys/net/if_pppoe.c | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/sys/net/if_pppoe.c b/sys/net/if_pppoe.c index d7db42c70b7..c44c7653fa0 100644 --- a/sys/net/if_pppoe.c +++ b/sys/net/if_pppoe.c @@ -1,4 +1,4 @@ -/* $OpenBSD: if_pppoe.c,v 1.3 2005/01/01 00:30:31 canacar Exp $ */ +/* $OpenBSD: if_pppoe.c,v 1.4 2005/06/07 05:10:57 canacar Exp $ */ /* $NetBSD: if_pppoe.c,v 1.51 2003/11/28 08:56:48 keihan Exp $ */ /* @@ -528,8 +528,7 @@ static void pppoe_dispatch_disc_pkt(struct mbuf *m, int off) printf("%s: %s: %*s\n", sc ? sc->sc_sppp.pp_if.if_xname : "pppoe*", err_msg, len, err_txt); - if (errortag) - goto done; + goto done; } off += sizeof(*pt) + len; } @@ -553,7 +552,9 @@ breakbreak: break; } if (sc == NULL) { - PPPOEDEBUG(("pppoe: free passive interface is not found\n")); +#ifdef PPPOE_DEBUG + printf("pppoe: free passive interface is not found\n"); +#endif goto done; } if (hunique) { |