diff options
Diffstat (limited to 'generic/tclCompCmdsSZ.c')
-rw-r--r-- | generic/tclCompCmdsSZ.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/generic/tclCompCmdsSZ.c b/generic/tclCompCmdsSZ.c index db01dcd..5c2a0b6 100644 --- a/generic/tclCompCmdsSZ.c +++ b/generic/tclCompCmdsSZ.c @@ -837,7 +837,7 @@ TclCompileStringLenCmd( char buf[TCL_INTEGER_SPACE]; int len = Tcl_GetCharLength(objPtr); - len = sprintf(buf, "%d", len); + len = snprintf(buf, sizeof(buf), "%d", len); PushLiteral(envPtr, buf, len); } else { SetLineInformation(1); @@ -3073,7 +3073,7 @@ IssueTryClausesInstructions( for (i=0 ; i<numHandlers ; i++) { noError[i] = -1; - sprintf(buf, "%d", matchCodes[i]); + snprintf(buf, sizeof(buf), "%d", matchCodes[i]); OP( DUP); PushLiteral(envPtr, buf, strlen(buf)); OP( EQ); @@ -3285,7 +3285,7 @@ IssueTryClausesFinallyInstructions( int noTrapError, trapError; const char *p; - sprintf(buf, "%d", matchCodes[i]); + snprintf(buf, sizeof(buf), "%d", matchCodes[i]); OP( DUP); PushLiteral(envPtr, buf, strlen(buf)); OP( EQ); |