More __func__ to fix error messages
authorkn <kn@openbsd.org>
Fri, 7 Sep 2018 21:37:03 +0000 (21:37 +0000)
committerkn <kn@openbsd.org>
Fri, 7 Sep 2018 21:37:03 +0000 (21:37 +0000)
sbin/pfctl/pfctl_parser.c

index 4d5b03a..2e8f703 100644 (file)
@@ -1,4 +1,4 @@
-/*     $OpenBSD: pfctl_parser.c,v 1.331 2018/09/07 14:16:22 kn Exp $ */
+/*     $OpenBSD: pfctl_parser.c,v 1.332 2018/09/07 21:37:03 kn Exp $ */
 
 /*
  * Copyright (c) 2001 Daniel Hartmeier
@@ -1352,7 +1352,7 @@ ifa_load(void)
                                continue;
                n = calloc(1, sizeof(struct node_host));
                if (n == NULL)
-                       err(1, "address: calloc");
+                       err(1, "%s: calloc", __func__);
                n->af = ifa->ifa_addr->sa_family;
                n->ifa_flags = ifa->ifa_flags;
 #ifdef __KAME__
@@ -1408,7 +1408,7 @@ ifa_load(void)
                            ifa->ifa_addr)->sdl_index;
                }
                if ((n->ifname = strdup(ifa->ifa_name)) == NULL)
-                       err(1, "ifa_load: strdup");
+                       err(1, "%s: strdup", __func__);
                n->next = NULL;
                n->tail = n;
                if (h == NULL)
@@ -1570,7 +1570,7 @@ ifa_lookup(const char *ifa_name, int flags)
                        got6 = 1;
                n = calloc(1, sizeof(struct node_host));
                if (n == NULL)
-                       err(1, "address: calloc");
+                       err(1, "%s: calloc", __func__);
                n->af = p->af;
                if (flags & PFI_AFLAG_BROADCAST)
                        memcpy(&n->addr.v.a.addr, &p->bcast,