diff options
author | 2020-01-15 22:38:30 +0000 | |
---|---|---|
committer | 2020-01-15 22:38:30 +0000 | |
commit | c802a0d9d6a6510e658984688f179f6777ccfce2 (patch) | |
tree | f5f4e610557b54cd6f0efdfb86fdc9c408369045 | |
parent | Unify error message for nonexisting anchors (diff) | |
download | wireguard-openbsd-c802a0d9d6a6510e658984688f179f6777ccfce2.tar.xz wireguard-openbsd-c802a0d9d6a6510e658984688f179f6777ccfce2.zip |
Do the actual pfr_strerror() to pf_strerror() rename
Missed in previous
-rw-r--r-- | sbin/pfctl/parse.y | 4 | ||||
-rw-r--r-- | sbin/pfctl/pfctl.c | 12 | ||||
-rw-r--r-- | sbin/pfctl/pfctl.h | 4 | ||||
-rw-r--r-- | sbin/pfctl/pfctl_optimize.c | 6 | ||||
-rw-r--r-- | sbin/pfctl/pfctl_table.c | 8 |
5 files changed, 17 insertions, 17 deletions
diff --git a/sbin/pfctl/parse.y b/sbin/pfctl/parse.y index fd8b3979110..d524f9e92bc 100644 --- a/sbin/pfctl/parse.y +++ b/sbin/pfctl/parse.y @@ -1,4 +1,4 @@ -/* $OpenBSD: parse.y,v 1.699 2019/10/17 21:54:28 millert Exp $ */ +/* $OpenBSD: parse.y,v 1.700 2020/01/15 22:38:30 kn Exp $ */ /* * Copyright (c) 2001 Markus Friedl. All rights reserved. @@ -4124,7 +4124,7 @@ process_tabledef(char *name, struct table_opts *opts, int popts) pfctl_define_table(name, opts->flags, opts->init_addr, pf->anchor->path, &ab, pf->anchor->ruleset.tticket)) { yyerror("cannot define table %s: %s", name, - pfr_strerror(errno)); + pf_strerror(errno)); goto _error; } pf->tdirty = 1; diff --git a/sbin/pfctl/pfctl.c b/sbin/pfctl/pfctl.c index 7bedc88db6e..5e00c7c4dae 100644 --- a/sbin/pfctl/pfctl.c +++ b/sbin/pfctl/pfctl.c @@ -1,4 +1,4 @@ -/* $OpenBSD: pfctl.c,v 1.380 2020/01/15 22:31:51 kn Exp $ */ +/* $OpenBSD: pfctl.c,v 1.381 2020/01/15 22:38:31 kn Exp $ */ /* * Copyright (c) 2001 Daniel Hartmeier @@ -863,7 +863,7 @@ pfctl_show_rules(int dev, char *path, int opts, enum pfctl_show format, if (opts & PF_OPT_SHOWALL) { pr.rule.action = PF_PASS; if (ioctl(dev, DIOCGETRULES, &pr) == -1) { - warnx("%s", pfr_strerror(errno)); + warnx("%s", pf_strerror(errno)); ret = -1; goto error; } @@ -878,7 +878,7 @@ pfctl_show_rules(int dev, char *path, int opts, enum pfctl_show format, pr.rule.action = PF_PASS; if (ioctl(dev, DIOCGETRULES, &pr) == -1) { - warnx("%s", pfr_strerror(errno)); + warnx("%s", pf_strerror(errno)); ret = -1; goto error; } @@ -979,7 +979,7 @@ pfctl_show_rules(int dev, char *path, int opts, enum pfctl_show format, for (nr = 0; nr < mnr; ++nr) { prs.nr = nr; if (ioctl(dev, DIOCGETRULESET, &prs) == -1) - errx(1, "%s", pfr_strerror(errno)); + errx(1, "%s", pf_strerror(errno)); INDENT(depth, !(opts & PF_OPT_VERBOSE)); printf("anchor \"%s\" all {\n", prs.name); pfctl_show_rules(dev, npath, opts, @@ -2219,7 +2219,7 @@ pfctl_walk_anchors(int dev, int opts, const char *anchor, pr.nr = nr; if (ioctl(dev, DIOCGETRULESET, &pr) == -1) - errx(1, "%s", pfr_strerror(errno)); + errx(1, "%s", pf_strerror(errno)); if (!strcmp(pr.name, PF_RESERVED_ANCHOR)) continue; sub[0] = '\0'; @@ -2895,7 +2895,7 @@ main(int argc, char *argv[]) } char * -pfr_strerror(int errnum) +pf_strerror(int errnum) { switch (errnum) { case ESRCH: diff --git a/sbin/pfctl/pfctl.h b/sbin/pfctl/pfctl.h index 5f3f6990a67..3c15c7e3207 100644 --- a/sbin/pfctl/pfctl.h +++ b/sbin/pfctl/pfctl.h @@ -1,4 +1,4 @@ -/* $OpenBSD: pfctl.h,v 1.61 2020/01/15 11:52:50 sashan Exp $ */ +/* $OpenBSD: pfctl.h,v 1.62 2020/01/15 22:38:31 kn Exp $ */ /* * Copyright (c) 2001 Daniel Hartmeier @@ -78,7 +78,7 @@ int pfr_buf_add(struct pfr_buffer *, const void *); void *pfr_buf_next(struct pfr_buffer *, const void *); int pfr_buf_grow(struct pfr_buffer *, int); int pfr_buf_load(struct pfr_buffer *, char *, int, int); -char *pfr_strerror(int); +char *pf_strerror(int); int pfi_get_ifaces(const char *, struct pfi_kif *, int *); int pfi_clr_istats(const char *, int *, int); diff --git a/sbin/pfctl/pfctl_optimize.c b/sbin/pfctl/pfctl_optimize.c index e9cdb1bb948..3526dcce962 100644 --- a/sbin/pfctl/pfctl_optimize.c +++ b/sbin/pfctl/pfctl_optimize.c @@ -1,4 +1,4 @@ -/* $OpenBSD: pfctl_optimize.c,v 1.44 2020/01/15 22:31:51 kn Exp $ */ +/* $OpenBSD: pfctl_optimize.c,v 1.45 2020/01/15 22:38:31 kn Exp $ */ /* * Copyright (c) 2004 Mike Frantzen <frantzen@openbsd.org> @@ -873,7 +873,7 @@ load_feedback_profile(struct pfctl *pf, struct superblocks *superblocks) memset(&pr, 0, sizeof(pr)); pr.rule.action = PF_PASS; if (ioctl(pf->dev, DIOCGETRULES, &pr) == -1) { - warnx("%s", pfr_strerror(errno)); + warnx("%s", pf_strerror(errno)); return (1); } mnr = pr.nr; @@ -887,7 +887,7 @@ load_feedback_profile(struct pfctl *pf, struct superblocks *superblocks) } pr.nr = nr; if (ioctl(pf->dev, DIOCGETRULE, &pr) == -1) { - warnx("%s", pfr_strerror(errno)); + warnx("%s", pf_strerror(errno)); free(por); return (1); } diff --git a/sbin/pfctl/pfctl_table.c b/sbin/pfctl/pfctl_table.c index 6c1466a1026..5c0c32e5961 100644 --- a/sbin/pfctl/pfctl_table.c +++ b/sbin/pfctl/pfctl_table.c @@ -1,4 +1,4 @@ -/* $OpenBSD: pfctl_table.c,v 1.83 2020/01/15 15:45:49 kn Exp $ */ +/* $OpenBSD: pfctl_table.c,v 1.84 2020/01/15 22:38:31 kn Exp $ */ /* * Copyright (c) 2002 Cedric Berger @@ -77,7 +77,7 @@ static const char *istats_text[2][2][2] = { (opts & PF_OPT_DUMMYACTION)) && \ (fct)) { \ if ((opts & PF_OPT_RECURSE) == 0) \ - warnx("%s", pfr_strerror(errno)); \ + warnx("%s", pf_strerror(errno)); \ goto _error; \ } \ } while (0) @@ -90,7 +90,7 @@ static const char *istats_text[2][2][2] = { (opts & PF_OPT_DUMMYACTION)) && \ (pfr_add_tables(&table, 1, &nadd, flags)) && \ (errno != EPERM)) { \ - warnx("%s", pfr_strerror(errno)); \ + warnx("%s", pf_strerror(errno)); \ goto _error; \ } \ if (nadd) { \ @@ -591,7 +591,7 @@ pfctl_show_ifaces(const char *filter, int opts) pfr_buf_grow(&b, b.pfrb_size); b.pfrb_size = b.pfrb_msize; if (pfi_get_ifaces(filter, b.pfrb_caddr, &b.pfrb_size)) - errx(1, "%s", pfr_strerror(errno)); + errx(1, "%s", pf_strerror(errno)); if (b.pfrb_size <= b.pfrb_msize) break; i++; |