summaryrefslogtreecommitdiffstats
path: root/hack/hack.pager.c
diff options
context:
space:
mode:
authorjoerg <joerg@NetBSD.org>2011-05-23 22:53:25 +0000
committerjoerg <joerg@NetBSD.org>2011-05-23 22:53:25 +0000
commitef178239f8a825e1c9dfde4c994a8eb7d680c9b2 (patch)
treeda736f35d02ffb7969f5aaebf7ca13bc8c3be666 /hack/hack.pager.c
parentdfc4f283126d2186a83011182f21659dd08bb35e (diff)
downloadbsdgames-darwin-ef178239f8a825e1c9dfde4c994a8eb7d680c9b2.tar.gz
bsdgames-darwin-ef178239f8a825e1c9dfde4c994a8eb7d680c9b2.zip
Correctly print variables as strings, not as format string.
Diffstat (limited to 'hack/hack.pager.c')
-rw-r--r--hack/hack.pager.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/hack/hack.pager.c b/hack/hack.pager.c
index eb6484be..dca670d8 100644
--- a/hack/hack.pager.c
+++ b/hack/hack.pager.c
@@ -1,4 +1,4 @@
-/* $NetBSD: hack.pager.c,v 1.14 2010/02/03 15:34:38 roy Exp $ */
+/* $NetBSD: hack.pager.c,v 1.15 2011/05/23 22:53:25 joerg Exp $ */
/*
* Copyright (c) 1985, Stichting Centrum voor Wiskunde en Informatica,
@@ -63,7 +63,7 @@
#include <sys/cdefs.h>
#ifndef lint
-__RCSID("$NetBSD: hack.pager.c,v 1.14 2010/02/03 15:34:38 roy Exp $");
+__RCSID("$NetBSD: hack.pager.c,v 1.15 2011/05/23 22:53:25 joerg Exp $");
#endif /* not lint */
/* This file contains the command routine dowhatis() and a pager. */
@@ -114,7 +114,7 @@ dowhatis(void)
buf[0] = q;
(void) strncpy(buf + 1, " ", 7);
}
- pline(buf);
+ pline("%s", buf);
if (ep[-1] == ';') {
pline("More info? ");
if (readchar() == 'y') {
@@ -302,7 +302,7 @@ cornline(int mode, const char *text)
}
/* --- now we really do it --- */
if (mode == 2 && linect == 1) /* topline only */
- pline(texthead->line_text);
+ pline("%s", texthead->line_text);
else if (mode == 2) {
int curline, lth;