summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authordgp <dgp@users.sourceforge.net>2009-06-15 18:51:35 (GMT)
committerdgp <dgp@users.sourceforge.net>2009-06-15 18:51:35 (GMT)
commit0cb4610865b2d7ca1536e0236d8915fd58b441fd (patch)
treee6f3763f1a0b237c327c9fe779ab30c3e53258aa
parent0acb18f87feafbdd931076405ca98c3ce30deca5 (diff)
downloadtcl-0cb4610865b2d7ca1536e0236d8915fd58b441fd.zip
tcl-0cb4610865b2d7ca1536e0236d8915fd58b441fd.tar.gz
tcl-0cb4610865b2d7ca1536e0236d8915fd58b441fd.tar.bz2
* generic/tclStringObj.c: sprintf() -> Tcl_ObjPrintf() conversion.
-rw-r--r--ChangeLog4
-rw-r--r--generic/tclStringObj.c8
2 files changed, 7 insertions, 5 deletions
diff --git a/ChangeLog b/ChangeLog
index 84b5b14..026c39b 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,7 @@
+2009-06-15 Don Porter <dgp@users.sourceforge.net>
+
+ * generic/tclStringObj.c: sprintf() -> Tcl_ObjPrintf() conversion.
+
2009-06-15 Reinhard Max <max@suse.de>
* unix/tclUnixPort.h: Move all socket-related code from tclUnixChan.c
diff --git a/generic/tclStringObj.c b/generic/tclStringObj.c
index ebc15b3..4535c64 100644
--- a/generic/tclStringObj.c
+++ b/generic/tclStringObj.c
@@ -33,7 +33,7 @@
* See the file "license.terms" for information on usage and redistribution of
* this file, and for a DISCLAIMER OF ALL WARRANTIES.
*
- * RCS: @(#) $Id: tclStringObj.c,v 1.124 2009/06/10 21:39:49 dgp Exp $ */
+ * RCS: @(#) $Id: tclStringObj.c,v 1.125 2009/06/15 18:51:35 dgp Exp $ */
#include "tclInt.h"
#include "tommath.h"
@@ -2247,10 +2247,8 @@ Tcl_AppendFormatToObj(
}
default:
if (interp != NULL) {
- char buf[40];
-
- sprintf(buf, "bad field specifier \"%c\"", ch);
- Tcl_SetObjResult(interp, Tcl_NewStringObj(buf, -1));
+ Tcl_SetObjResult(interp,
+ Tcl_ObjPrintf("bad field specifier \"%c\"", ch));
}
goto error;
}