summaryrefslogtreecommitdiffstats
path: root/generic/tclBasic.c
diff options
context:
space:
mode:
authordgp <dgp@users.sourceforge.net>2003-05-12 20:16:07 (GMT)
committerdgp <dgp@users.sourceforge.net>2003-05-12 20:16:07 (GMT)
commitd5e33f3849f201d600fcce1377b1e7948450f462 (patch)
treec019cafc5b002a7224374f6100d3f8051d163d12 /generic/tclBasic.c
parent7c6ff191e201e11d2fd8862bf834685acf4c9ddf (diff)
downloadtcl-d5e33f3849f201d600fcce1377b1e7948450f462.zip
tcl-d5e33f3849f201d600fcce1377b1e7948450f462.tar.gz
tcl-d5e33f3849f201d600fcce1377b1e7948450f462.tar.bz2
* generic/tclBasic.c (TclInvokeObjectCommand): objv[argc] is no
longer set to NULL (Tcl_CreateObjCommand docs already say that it should not be accessed).
Diffstat (limited to 'generic/tclBasic.c')
-rw-r--r--generic/tclBasic.c7
1 files changed, 3 insertions, 4 deletions
diff --git a/generic/tclBasic.c b/generic/tclBasic.c
index 0ad0818..8eda27e 100644
--- a/generic/tclBasic.c
+++ b/generic/tclBasic.c
@@ -13,7 +13,7 @@
* See the file "license.terms" for information on usage and redistribution
* of this file, and for a DISCLAIMER OF ALL WARRANTIES.
*
- * RCS: @(#) $Id: tclBasic.c,v 1.75.2.2 2003/05/05 16:52:33 dkf Exp $
+ * RCS: @(#) $Id: tclBasic.c,v 1.75.2.3 2003/05/12 20:16:08 dgp Exp $
*/
#include "tclInt.h"
@@ -1837,9 +1837,9 @@ TclInvokeObjectCommand(clientData, interp, argc, argv)
* end-of-objv word.
*/
- if ((argc + 1) > NUM_ARGS) {
+ if (argc > NUM_ARGS) {
objv = (Tcl_Obj **)
- ckalloc((unsigned)(argc + 1) * sizeof(Tcl_Obj *));
+ ckalloc((unsigned)(argc * sizeof(Tcl_Obj *)));
}
for (i = 0; i < argc; i++) {
@@ -1849,7 +1849,6 @@ TclInvokeObjectCommand(clientData, interp, argc, argv)
Tcl_IncrRefCount(objPtr);
objv[i] = objPtr;
}
- objv[argc] = 0;
/*
* Invoke the command's object-based Tcl_ObjCmdProc.