diff options
-rw-r--r-- | ChangeLog | 5 | ||||
-rw-r--r-- | generic/tclIOUtil.c | 13 |
2 files changed, 15 insertions, 3 deletions
@@ -1,3 +1,8 @@ +2003-11-07 Vince Darley <vincentdarley@users.sourceforge.net> + + * generic/tclIOUtil.c: fix to compiler warning/error with + some compilers [Bug 835918] + 2003-11-07 Daniel Steffen <das@users.sourceforge.net> * macosx/Makefile: optimized builds define NDEBUG to turn off diff --git a/generic/tclIOUtil.c b/generic/tclIOUtil.c index ce510e0..083152e 100644 --- a/generic/tclIOUtil.c +++ b/generic/tclIOUtil.c @@ -17,7 +17,7 @@ * See the file "license.terms" for information on usage and redistribution * of this file, and for a DISCLAIMER OF ALL WARRANTIES. * - * RCS: @(#) $Id: tclIOUtil.c,v 1.88 2003/11/03 12:49:31 vincentdarley Exp $ + * RCS: @(#) $Id: tclIOUtil.c,v 1.89 2003/11/07 11:36:47 vincentdarley Exp $ */ #include "tclInt.h" @@ -2528,11 +2528,18 @@ Tcl_FSLoadFile(interp, pathPtr, sym1, sym2, proc1Ptr, proc2Ptr, * function which should be used for * this file. */ { - CONST char *symbols[] = { sym1, sym2 }; - Tcl_PackageInitProc **procPtrs[] = { proc1Ptr, proc2Ptr }; + CONST char *symbols[2]; + Tcl_PackageInitProc **procPtrs[2]; ClientData clientData; int res; + /* Initialize the arrays */ + symbols[0] = sym1; + symbols[1] = sym2; + procPtrs[0] = proc1Ptr; + procPtrs[1] = proc2Ptr; + + /* Perform the load */ res = TclLoadFile(interp, pathPtr, 2, symbols, procPtrs, handlePtr, &clientData, unloadProcPtr); |