summaryrefslogtreecommitdiff
path: root/bin/expr/expr.c
diff options
context:
space:
mode:
authorTodd C. Miller <millert@cvs.openbsd.org>1996-09-15 22:27:39 +0000
committerTodd C. Miller <millert@cvs.openbsd.org>1996-09-15 22:27:39 +0000
commita1d30f6274565f7c1a66c195d68d90798aac89b8 (patch)
tree61103d64e2f12fb4ac40394b70851e267c1c770d /bin/expr/expr.c
parent733966b6e5cfde760f42ebed60f7e0efeeddf8cb (diff)
sprintf -> snprintf paranoia
Diffstat (limited to 'bin/expr/expr.c')
-rw-r--r--bin/expr/expr.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/bin/expr/expr.c b/bin/expr/expr.c
index 14538ee5b87..49b1736ba8e 100644
--- a/bin/expr/expr.c
+++ b/bin/expr/expr.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: expr.c,v 1.3 1996/06/23 14:20:10 deraadt Exp $ */
+/* $OpenBSD: expr.c,v 1.4 1996/09/15 22:27:38 millert Exp $ */
/* $NetBSD: expr.c,v 1.3.6.1 1996/06/04 20:41:47 cgd Exp $ */
/*
@@ -157,7 +157,7 @@ to_string(vp)
if (tmp == NULL) {
err(2, NULL);
}
- sprintf(tmp, "%d", vp->u.i);
+ snprintf(tmp, 25, "%d", vp->u.i);
vp->type = string;
vp->u.s = tmp;
}