From a623d7c672cb99301a9e7f294ee836f9795f5af5 Mon Sep 17 00:00:00 2001 From: dholland Date: Tue, 26 May 2009 00:00:56 +0000 Subject: sprintf -> snprintf --- atc/input.c | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) (limited to 'atc/input.c') diff --git a/atc/input.c b/atc/input.c index 215c3c30..a2b49f5a 100644 --- a/atc/input.c +++ b/atc/input.c @@ -1,4 +1,4 @@ -/* $NetBSD: input.c,v 1.22 2007/12/15 19:44:38 perry Exp $ */ +/* $NetBSD: input.c,v 1.23 2009/05/26 00:00:56 dholland Exp $ */ /*- * Copyright (c) 1990, 1993 @@ -46,7 +46,7 @@ #if 0 static char sccsid[] = "@(#)input.c 8.1 (Berkeley) 5/31/93"; #else -__RCSID("$NetBSD: input.c,v 1.22 2007/12/15 19:44:38 perry Exp $"); +__RCSID("$NetBSD: input.c,v 1.23 2009/05/26 00:00:56 dholland Exp $"); #endif #endif /* not lint */ @@ -208,7 +208,8 @@ push(int ruleno, int ch) int newstate, newpos; assert(level < (MAXDEPTH - 1)); - (void)sprintf(T_STR, st[T_STATE].rule[ruleno].str, tval); + (void)snprintf(T_STR, sizeof(T_STR), + st[T_STATE].rule[ruleno].str, tval); T_RULE = ruleno; T_CH = ch; newstate = st[T_STATE].rule[ruleno].to_state; -- cgit v1.2.3