You are viewing a plain text version of this content. The canonical link for it is here.
Posted to websh-cvs@tcl.apache.org by ro...@apache.org on 2003/11/15 01:00:30 UTC
cvs commit: tcl-websh/src/generic interpool.c
ronnie 2003/11/14 16:00:30
Modified: src/generic interpool.c
Log:
- bug fix in call to web::interpmap (file names with spaces)
Revision Changes Path
1.18 +9 -3 tcl-websh/src/generic/interpool.c
Index: interpool.c
===================================================================
RCS file: /home/cvs/tcl-websh/src/generic/interpool.c,v
retrieving revision 1.17
retrieving revision 1.18
diff -u -r1.17 -r1.18
--- interpool.c 25 Jul 2002 17:43:01 -0000 1.17
+++ interpool.c 15 Nov 2003 00:00:30 -0000 1.18
@@ -295,17 +295,23 @@
char *id = NULL;
Tcl_Obj *idObj = NULL;
Tcl_Obj *mapCmd = NULL;
+ Tcl_Obj *cmdList[2];
int res;
/* get interpreter id for filename */
Tcl_MutexLock(&(conf->mainInterpLock));
- mapCmd = Tcl_NewStringObj("web::interpmap ", -1);
+ cmdList[0] = Tcl_NewStringObj("web::interpmap", -1);
+ cmdList[1] = Tcl_NewStringObj(filename, -1);
+ Tcl_IncrRefCount(cmdList[0]);
+ Tcl_IncrRefCount(cmdList[1]);
+ mapCmd = Tcl_NewListObj(2, cmdList);
Tcl_IncrRefCount(mapCmd);
- Tcl_AppendToObj(mapCmd, filename, -1);
res = Tcl_EvalObjEx(conf->mainInterp, mapCmd, 0);
Tcl_DecrRefCount(mapCmd);
+ Tcl_DecrRefCount(cmdList[0]);
+ Tcl_DecrRefCount(cmdList[1]);
idObj = Tcl_DuplicateObj(Tcl_GetObjResult(conf->mainInterp));
Tcl_ResetResult(conf->mainInterp);
---------------------------------------------------------------------
To unsubscribe, e-mail: websh-cvs-unsubscribe@tcl.apache.org
For additional commands, e-mail: websh-cvs-help@tcl.apache.org