Date: Mon, 20 Jul 2026 11:51:11 +0000 From: Baptiste Daroussin <bapt@FreeBSD.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org Subject: git: 8966cc0d01a2 - main - m4: import fixes from OpenBSD Message-ID: <6a5e0baf.3b0c2.2e6bbed@gitrepo.freebsd.org>
index | next in thread | raw e-mail
The branch main has been updated by bapt: URL: https://cgit.FreeBSD.org/src/commit/?id=8966cc0d01a29c11168e4e9d7f1703aa31ad3be6 commit 8966cc0d01a29c11168e4e9d7f1703aa31ad3be6 Author: Baptiste Daroussin <bapt@FreeBSD.org> AuthorDate: 2026-07-19 18:43:31 +0000 Commit: Baptiste Daroussin <bapt@FreeBSD.org> CommitDate: 2026-07-20 11:49:42 +0000 m4: import fixes from OpenBSD - gnum4.c: fix m4_warnx() to use vwarnx() instead of warnx() - eval.c: improve error messages for empty macro names - extern.h: remove compute_prevep() declaration - Update OpenBSD version strings MFC After: 3 days --- usr.bin/m4/eval.c | 6 +++--- usr.bin/m4/extern.h | 3 +-- usr.bin/m4/gnum4.c | 4 ++-- usr.bin/m4/look.c | 2 +- 4 files changed, 7 insertions(+), 8 deletions(-) diff --git a/usr.bin/m4/eval.c b/usr.bin/m4/eval.c index 4f088e0415e0..6f96b5555965 100644 --- a/usr.bin/m4/eval.c +++ b/usr.bin/m4/eval.c @@ -1,4 +1,4 @@ -/* $OpenBSD: eval.c,v 1.78 2019/06/28 05:35:34 deraadt Exp $ */ +/* $OpenBSD: eval.c,v 1.81 2026/02/25 05:37:25 op Exp $ */ /* $NetBSD: eval.c,v 1.7 1996/11/10 21:21:29 pk Exp $ */ /*- @@ -598,7 +598,7 @@ void dodefine(const char *name, const char *defn) { if (!*name && !mimic_gnu) - m4errx(1, "null definition."); + m4errx(1, "define macro with empty name."); else macro_define(name, defn); } @@ -635,7 +635,7 @@ static void dopushdef(const char *name, const char *defn) { if (!*name && !mimic_gnu) - m4errx(1, "null definition."); + m4errx(1, "pushdef macro with empty name."); else macro_pushdef(name, defn); } diff --git a/usr.bin/m4/extern.h b/usr.bin/m4/extern.h index a411cb6d5891..bdee26be56bd 100644 --- a/usr.bin/m4/extern.h +++ b/usr.bin/m4/extern.h @@ -1,4 +1,4 @@ -/* $OpenBSD: extern.h,v 1.55 2017/06/15 13:48:42 bcallah Exp $ */ +/* $OpenBSD: extern.h,v 1.57 2026/02/25 05:37:25 op Exp $ */ /* $NetBSD: extern.h,v 1.3 1996/01/13 23:25:24 pk Exp $ */ /*- @@ -93,7 +93,6 @@ extern int exit_code; /* misc.c */ extern void chrsave(int); -extern char *compute_prevep(void); extern void getdiv(int); extern ptrdiff_t doindex(const char *, const char *); extern void initspaces(void); diff --git a/usr.bin/m4/gnum4.c b/usr.bin/m4/gnum4.c index ecd89b5c8b6a..d7201533cb1a 100644 --- a/usr.bin/m4/gnum4.c +++ b/usr.bin/m4/gnum4.c @@ -1,4 +1,4 @@ -/* $OpenBSD: gnum4.c,v 1.52 2017/08/21 21:41:13 deraadt Exp $ */ +/* $OpenBSD: gnum4.c,v 1.55 2025/11/05 17:10:45 tb Exp $ */ /*- * SPDX-License-Identifier: BSD-2-Clause @@ -267,7 +267,7 @@ m4_warnx(const char *fmt, ...) va_list ap; va_start(ap, fmt); - warnx(fmt, ap); + vwarnx(fmt, ap); va_end(ap); if (fatal_warns) diff --git a/usr.bin/m4/look.c b/usr.bin/m4/look.c index c1fccd7dd8e5..c084baef30cf 100644 --- a/usr.bin/m4/look.c +++ b/usr.bin/m4/look.c @@ -1,4 +1,4 @@ -/* $OpenBSD: look.c,v 1.24 2014/12/21 09:33:12 espie Exp $ */ +/* $OpenBSD: look.c,v 1.26 2026/02/25 05:37:25 op Exp $ */ /*- * SPDX-License-Identifier: BSD-3-Clausehome | help
Want to link to this message? Use this
URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?6a5e0baf.3b0c2.2e6bbed>
