summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorjan.nijtmans <nijtmans@users.sourceforge.net>2012-10-24 11:21:31 (GMT)
committerjan.nijtmans <nijtmans@users.sourceforge.net>2012-10-24 11:21:31 (GMT)
commit8dfd4b7f0268e1515691149fa13814aae8742cec (patch)
treea9698a8be1ec73cd1f21ff7788d8a684ee4ea439
parent7927604b9490feecc8f9e5331b8e6e2cb5005b19 (diff)
parentee55e87c478c26094a52d1c38d702b67e4a1c4cb (diff)
downloadtcl-8dfd4b7f0268e1515691149fa13814aae8742cec.zip
tcl-8dfd4b7f0268e1515691149fa13814aae8742cec.tar.gz
tcl-8dfd4b7f0268e1515691149fa13814aae8742cec.tar.bz2
Add dummy 0 parameter (unused flags) to internal Tcl_FSLoadFileProc call, for upwards compatibility with version 2 filesystems
-rw-r--r--generic/tclIOUtil.c6
-rw-r--r--generic/tclTest.c2
2 files changed, 6 insertions, 2 deletions
diff --git a/generic/tclIOUtil.c b/generic/tclIOUtil.c
index 1e600cd..f90bf0d 100644
--- a/generic/tclIOUtil.c
+++ b/generic/tclIOUtil.c
@@ -3149,6 +3149,9 @@ Tcl_FSLoadFile(
*----------------------------------------------------------------------
*/
+typedef int (Tcl_FSLoadFileProc2) (Tcl_Interp *interp, Tcl_Obj *pathPtr,
+ Tcl_LoadHandle *handlePtr, Tcl_FSUnloadFileProc **unloadProcPtr, int flags);
+
int
TclLoadFile(
Tcl_Interp *interp, /* Used for error reporting. */
@@ -3189,7 +3192,8 @@ TclLoadFile(
proc = fsPtr->loadFileProc;
if (proc != NULL) {
- int retVal = (*proc)(interp, pathPtr, handlePtr, unloadProcPtr);
+ int retVal = ((Tcl_FSLoadFileProc2 *)proc)
+ (interp, pathPtr, handlePtr, unloadProcPtr, 0);
if (retVal == TCL_OK) {
if (*handlePtr == NULL) {
return TCL_ERROR;
diff --git a/generic/tclTest.c b/generic/tclTest.c
index 9a1d0af..3c39a40 100644
--- a/generic/tclTest.c
+++ b/generic/tclTest.c
@@ -479,7 +479,7 @@ static Tcl_Filesystem testReportingFilesystem = {
&TestReportRenameFile,
&TestReportCopyDirectory,
&TestReportLstat,
- &TestReportLoadFile,
+ (Tcl_FSLoadFileProc *) &TestReportLoadFile,
NULL /* cwd */,
&TestReportChdir
};