From 0a160ce39b2682a3682e54a6aa8937d852c1adb1 Mon Sep 17 00:00:00 2001 From: okan Date: Mon, 24 Oct 2016 17:39:38 +0000 Subject: Sprinkle __func__ in appropriate error messages. --- kbfunc.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'kbfunc.c') diff --git a/kbfunc.c b/kbfunc.c index c1309a6..9af89d9 100644 --- a/kbfunc.c +++ b/kbfunc.c @@ -15,7 +15,7 @@ * ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF * OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. * - * $OpenBSD: kbfunc.c,v 1.132 2016/10/18 17:03:30 okan Exp $ + * $OpenBSD: kbfunc.c,v 1.133 2016/10/24 17:39:38 okan Exp $ */ #include @@ -405,7 +405,7 @@ kbfunc_menu_exec(void *ctx, union arg *arg, enum xev xev) label = "wm"; break; default: - errx(1, "kbfunc_menu_exec: invalid cmd %d", cmd); + errx(1, "%s: invalid cmd %d", __func__, cmd); /* NOTREACHED */ } @@ -456,7 +456,7 @@ kbfunc_menu_exec(void *ctx, union arg *arg, enum xev xev) Conf.wm_argv = xstrdup(mi->text); break; default: - errx(1, "kb_func: egad, cmd changed value!"); + errx(1, "%s: egad, cmd changed value!", __func__); /* NOTREACHED */ } } @@ -487,7 +487,7 @@ kbfunc_menu_ssh(void *ctx, union arg *arg, enum xev xev) TAILQ_INIT(&menuq); if ((fp = fopen(Conf.known_hosts, "r")) == NULL) { - warn("kbfunc_menu_ssh: %s", Conf.known_hosts); + warn("%s: %s", __func__, Conf.known_hosts); goto menu; } -- cgit v1.2.3-2-gb3c3