From eb159e28d9bb4066a3a342f9a6a9985d8c81eae2 Mon Sep 17 00:00:00 2001 From: Nayden Markatchev Date: Wed, 11 Jul 2018 21:18:24 +0000 Subject: Disambiguate the source of panics in sys/net* by adding __func__ magic constant to panic() calls. ok benno@ henning@ tb@ --- sys/net/pf_if.c | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) (limited to 'sys/net/pf_if.c') diff --git a/sys/net/pf_if.c b/sys/net/pf_if.c index 7ea1f05ea16..827ecb097d7 100644 --- a/sys/net/pf_if.c +++ b/sys/net/pf_if.c @@ -1,4 +1,4 @@ -/* $OpenBSD: pf_if.c,v 1.94 2018/07/11 09:05:51 henning Exp $ */ +/* $OpenBSD: pf_if.c,v 1.95 2018/07/11 21:18:23 nayden Exp $ */ /* * Copyright 2005 Henning Brauer @@ -227,7 +227,7 @@ pfi_attach_ifnet(struct ifnet *ifp) pfi_initialize(); pfi_update++; if ((kif = pfi_kif_get(ifp->if_xname)) == NULL) - panic("pfi_kif_get failed"); + panic("%s: pfi_kif_get failed", __func__); kif->pfik_ifp = ifp; ifp->if_pf_kif = (caddr_t)kif; @@ -265,7 +265,7 @@ pfi_attach_ifgroup(struct ifg_group *ifg) pfi_initialize(); pfi_update++; if ((kif = pfi_kif_get(ifg->ifg_group)) == NULL) - panic("pfi_kif_get failed"); + panic("%s: pfi_kif_get failed", __func__); kif->pfik_group = ifg; ifg->ifg_pf_kif = (caddr_t)kif; @@ -293,7 +293,7 @@ pfi_group_change(const char *group) pfi_update++; if ((kif = pfi_kif_get(group)) == NULL) - panic("pfi_kif_get failed"); + panic("%s: pfi_kif_get failed", __func__); pfi_kif_update(kif); } @@ -305,7 +305,7 @@ pfi_group_addmember(const char *group, struct ifnet *ifp) if ((gkif = pfi_kif_get(group)) == NULL || (ikif = pfi_kif_get(ifp->if_xname)) == NULL) - panic("pfi_kif_get failed"); + panic("%s: pfi_kif_get failed", __func__); ikif->pfik_flags |= gkif->pfik_flags; pfi_group_change(group); -- cgit v1.2.3