summaryrefslogtreecommitdiffstats
path: root/usr.bin
diff options
context:
space:
mode:
authorkris <kris@FreeBSD.org>2000-07-07 00:24:13 +0000
committerkris <kris@FreeBSD.org>2000-07-07 00:24:13 +0000
commit52c3440151cc84bca50f0ef9974328d635747444 (patch)
treef46a13463d61f87ebfc35093344d17c91d62118d /usr.bin
parent9912b3bfc676e900a5adf2ab9dc66b027efa8ea0 (diff)
downloadFreeBSD-src-52c3440151cc84bca50f0ef9974328d635747444.zip
FreeBSD-src-52c3440151cc84bca50f0ef9974328d635747444.tar.gz
MFS: Don't allow printf directives in PAGER
Obtained from: OpenBSD
Diffstat (limited to 'usr.bin')
-rw-r--r--usr.bin/msgs/msgs.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/usr.bin/msgs/msgs.c b/usr.bin/msgs/msgs.c
index 1753640..e1db2fc 100644
--- a/usr.bin/msgs/msgs.c
+++ b/usr.bin/msgs/msgs.c
@@ -634,7 +634,7 @@ int length;
if ((env_pager = getenv("PAGER")) == NULL) {
snprintf(cmdbuf, sizeof(cmdbuf), _PATH_PAGER, Lpp);
} else {
- snprintf(cmdbuf, sizeof(cmdbuf), env_pager);
+ snprintf(cmdbuf, sizeof(cmdbuf), "%s", env_pager);
}
outf = popen(cmdbuf, "w");
if (!outf)
OpenPOWER on IntegriCloud