diff options
author | jan.nijtmans <nijtmans@users.sourceforge.net> | 2020-07-16 08:35:24 (GMT) |
---|---|---|
committer | jan.nijtmans <nijtmans@users.sourceforge.net> | 2020-07-16 08:35:24 (GMT) |
commit | 409c16469555a47e4827c4b8415940a53841676e (patch) | |
tree | 07e74dc7f73925b8e5430433f7cdf25d7ba538d5 | |
parent | 02b1b013df6db99985c373a714155ddd29c8819d (diff) | |
parent | 439f72dad506c9f5143db634365aab3375b8c532 (diff) | |
download | tcl-409c16469555a47e4827c4b8415940a53841676e.zip tcl-409c16469555a47e4827c4b8415940a53841676e.tar.gz tcl-409c16469555a47e4827c4b8415940a53841676e.tar.bz2 |
Merge 8.6
-rw-r--r-- | doc/CrtAlias.3 (renamed from doc/CrtSlave.3) | 10 | ||||
-rw-r--r-- | generic/tcl.decls | 2 | ||||
-rw-r--r-- | generic/tclDecls.h | 4 | ||||
-rw-r--r-- | generic/tclExecute.c | 18 | ||||
-rw-r--r-- | macosx/Tcl.xcode/project.pbxproj | 4 | ||||
-rw-r--r-- | macosx/Tcl.xcodeproj/project.pbxproj | 4 | ||||
-rw-r--r-- | win/tcl.dsp | 2 |
7 files changed, 30 insertions, 14 deletions
diff --git a/doc/CrtSlave.3 b/doc/CrtAlias.3 index b8ac421..72912bc 100644 --- a/doc/CrtSlave.3 +++ b/doc/CrtAlias.3 @@ -4,7 +4,7 @@ '\" See the file "license.terms" for information on usage and redistribution '\" of this file, and for a DISCLAIMER OF ALL WARRANTIES. '\" -.TH Tcl_CreateSlave 3 7.6 Tcl "Tcl Library Procedures" +.TH Tcl_CreateAlias 3 7.6 Tcl "Tcl Library Procedures" .so man.macros .BS .SH NAME @@ -20,16 +20,16 @@ int \fBTcl_MakeSafe\fR(\fIinterp\fR) .sp Tcl_Interp * -\fBTcl_CreateSlave\fR(\fIinterp, slaveName, isSafe\fR) +\fBTcl_CreateSlave\fR(\fIinterp, name, isSafe\fR) .sp Tcl_Interp * -\fBTcl_GetSlave\fR(\fIinterp, slaveName\fR) +\fBTcl_GetSlave\fR(\fIinterp, name\fR) .sp Tcl_Interp * \fBTcl_GetMaster\fR(\fIinterp\fR) .sp int -\fBTcl_GetInterpPath\fR(\fIaskingInterp, slaveInterp\fR) +\fBTcl_GetInterpPath\fR(\finterp, slaveInterp\fR) .sp int \fBTcl_CreateAlias\fR(\fIslaveInterp, slaveCmd, targetInterp, targetCmd, @@ -56,7 +56,7 @@ int .AS "const char *const" **targetInterpPtr out .AP Tcl_Interp *interp in Interpreter in which to execute the specified command. -.AP "const char" *slaveName in +.AP "const char" *name in Name of slave interpreter to create or manipulate. .AP int isSafe in If non-zero, a diff --git a/generic/tcl.decls b/generic/tcl.decls index 7cd3fd2..6f35631 100644 --- a/generic/tcl.decls +++ b/generic/tcl.decls @@ -582,7 +582,7 @@ declare 162 { CONST84_RETURN char *Tcl_GetHostName(void) } declare 163 { - int Tcl_GetInterpPath(Tcl_Interp *askInterp, Tcl_Interp *slaveInterp) + int Tcl_GetInterpPath(Tcl_Interp *interp, Tcl_Interp *slaveInterp) } declare 164 { Tcl_Interp *Tcl_GetMaster(Tcl_Interp *interp) diff --git a/generic/tclDecls.h b/generic/tclDecls.h index 037b6e5..e341731 100644 --- a/generic/tclDecls.h +++ b/generic/tclDecls.h @@ -503,7 +503,7 @@ EXTERN int Tcl_GetErrno(void); /* 162 */ EXTERN CONST84_RETURN char * Tcl_GetHostName(void); /* 163 */ -EXTERN int Tcl_GetInterpPath(Tcl_Interp *askInterp, +EXTERN int Tcl_GetInterpPath(Tcl_Interp *interp, Tcl_Interp *slaveInterp); /* 164 */ EXTERN Tcl_Interp * Tcl_GetMaster(Tcl_Interp *interp); @@ -2026,7 +2026,7 @@ typedef struct TclStubs { CONST84_RETURN char * (*tcl_GetCommandName) (Tcl_Interp *interp, Tcl_Command command); /* 160 */ int (*tcl_GetErrno) (void); /* 161 */ CONST84_RETURN char * (*tcl_GetHostName) (void); /* 162 */ - int (*tcl_GetInterpPath) (Tcl_Interp *askInterp, Tcl_Interp *slaveInterp); /* 163 */ + int (*tcl_GetInterpPath) (Tcl_Interp *interp, Tcl_Interp *slaveInterp); /* 163 */ Tcl_Interp * (*tcl_GetMaster) (Tcl_Interp *interp); /* 164 */ const char * (*tcl_GetNameOfExecutable) (void); /* 165 */ Tcl_Obj * (*tcl_GetObjResult) (Tcl_Interp *interp); /* 166 */ diff --git a/generic/tclExecute.c b/generic/tclExecute.c index 76feb79..dd82f95 100644 --- a/generic/tclExecute.c +++ b/generic/tclExecute.c @@ -2214,6 +2214,22 @@ TEBCresume( if (!pc) { /* bytecode is starting from scratch */ pc = codePtr->codeStart; + + /* + * Reset the interp's result to avoid possible duplications of large + * objects [3c6e47363e], [781585], [804681], This can happen by start + * also in nested compiled blocks (enclosed in parent cycle). + * See else branch below for opposite handling by continuation/resume. + */ + + objPtr = iPtr->objResultPtr; + if (objPtr->refCount > 1) { + TclDecrRefCount(objPtr); + TclNewObj(objPtr); + Tcl_IncrRefCount(objPtr); + iPtr->objResultPtr = objPtr; + } + goto cleanup0; } else { /* resume from invocation */ @@ -2253,7 +2269,7 @@ TEBCresume( objc, cmdNameBuf), Tcl_GetObjResult(interp)); /* - * Reset the interp's result to avoid possible duplications of large + * Obtain and reset interp's result to avoid possible duplications of * objects [Bug 781585]. We do not call Tcl_ResetResult to avoid any * side effects caused by the resetting of errorInfo and errorCode * [Bug 804681], which are not needed here. We chose instead to diff --git a/macosx/Tcl.xcode/project.pbxproj b/macosx/Tcl.xcode/project.pbxproj index 788aa8d..06c7fa0 100644 --- a/macosx/Tcl.xcode/project.pbxproj +++ b/macosx/Tcl.xcode/project.pbxproj @@ -263,7 +263,7 @@ F96D3E1F08F272A5004A47F5 /* CrtInterp.3 */ = {isa = PBXFileReference; explicitFileType = text.man; fileEncoding = 4; path = CrtInterp.3; sourceTree = "<group>"; }; F96D3E2008F272A5004A47F5 /* CrtMathFnc.3 */ = {isa = PBXFileReference; explicitFileType = text.man; fileEncoding = 4; path = CrtMathFnc.3; sourceTree = "<group>"; }; F96D3E2108F272A5004A47F5 /* CrtObjCmd.3 */ = {isa = PBXFileReference; explicitFileType = text.man; fileEncoding = 4; path = CrtObjCmd.3; sourceTree = "<group>"; }; - F96D3E2208F272A5004A47F5 /* CrtSlave.3 */ = {isa = PBXFileReference; explicitFileType = text.man; fileEncoding = 4; path = CrtSlave.3; sourceTree = "<group>"; }; + F96D3E2208F272A5004A47F5 /* CrtAlias.3 */ = {isa = PBXFileReference; explicitFileType = text.man; fileEncoding = 4; path = CrtAlias.3; sourceTree = "<group>"; }; F96D3E2308F272A5004A47F5 /* CrtTimerHdlr.3 */ = {isa = PBXFileReference; explicitFileType = text.man; fileEncoding = 4; path = CrtTimerHdlr.3; sourceTree = "<group>"; }; F96D3E2408F272A5004A47F5 /* CrtTrace.3 */ = {isa = PBXFileReference; explicitFileType = text.man; fileEncoding = 4; path = CrtTrace.3; sourceTree = "<group>"; }; F96D3E2508F272A5004A47F5 /* dde.n */ = {isa = PBXFileReference; explicitFileType = text.man; fileEncoding = 4; path = dde.n; sourceTree = "<group>"; }; @@ -1013,7 +1013,7 @@ F96D3E1F08F272A5004A47F5 /* CrtInterp.3 */, F96D3E2008F272A5004A47F5 /* CrtMathFnc.3 */, F96D3E2108F272A5004A47F5 /* CrtObjCmd.3 */, - F96D3E2208F272A5004A47F5 /* CrtSlave.3 */, + F96D3E2208F272A5004A47F5 /* CrtAlias.3 */, F96D3E2308F272A5004A47F5 /* CrtTimerHdlr.3 */, F96D3E2408F272A5004A47F5 /* CrtTrace.3 */, F96D3E2508F272A5004A47F5 /* dde.n */, diff --git a/macosx/Tcl.xcodeproj/project.pbxproj b/macosx/Tcl.xcodeproj/project.pbxproj index 4362739..a0d4f2a 100644 --- a/macosx/Tcl.xcodeproj/project.pbxproj +++ b/macosx/Tcl.xcodeproj/project.pbxproj @@ -263,7 +263,7 @@ F96D3E1F08F272A5004A47F5 /* CrtInterp.3 */ = {isa = PBXFileReference; explicitFileType = text.man; fileEncoding = 4; path = CrtInterp.3; sourceTree = "<group>"; }; F96D3E2008F272A5004A47F5 /* CrtMathFnc.3 */ = {isa = PBXFileReference; explicitFileType = text.man; fileEncoding = 4; path = CrtMathFnc.3; sourceTree = "<group>"; }; F96D3E2108F272A5004A47F5 /* CrtObjCmd.3 */ = {isa = PBXFileReference; explicitFileType = text.man; fileEncoding = 4; path = CrtObjCmd.3; sourceTree = "<group>"; }; - F96D3E2208F272A5004A47F5 /* CrtSlave.3 */ = {isa = PBXFileReference; explicitFileType = text.man; fileEncoding = 4; path = CrtSlave.3; sourceTree = "<group>"; }; + F96D3E2208F272A5004A47F5 /* CrtAlias.3 */ = {isa = PBXFileReference; explicitFileType = text.man; fileEncoding = 4; path = CrtAlias.3; sourceTree = "<group>"; }; F96D3E2308F272A5004A47F5 /* CrtTimerHdlr.3 */ = {isa = PBXFileReference; explicitFileType = text.man; fileEncoding = 4; path = CrtTimerHdlr.3; sourceTree = "<group>"; }; F96D3E2408F272A5004A47F5 /* CrtTrace.3 */ = {isa = PBXFileReference; explicitFileType = text.man; fileEncoding = 4; path = CrtTrace.3; sourceTree = "<group>"; }; F96D3E2508F272A5004A47F5 /* dde.n */ = {isa = PBXFileReference; explicitFileType = text.man; fileEncoding = 4; path = dde.n; sourceTree = "<group>"; }; @@ -1013,7 +1013,7 @@ F96D3E1F08F272A5004A47F5 /* CrtInterp.3 */, F96D3E2008F272A5004A47F5 /* CrtMathFnc.3 */, F96D3E2108F272A5004A47F5 /* CrtObjCmd.3 */, - F96D3E2208F272A5004A47F5 /* CrtSlave.3 */, + F96D3E2208F272A5004A47F5 /* CrtAlias.3 */, F96D3E2308F272A5004A47F5 /* CrtTimerHdlr.3 */, F96D3E2408F272A5004A47F5 /* CrtTrace.3 */, F96D3E2508F272A5004A47F5 /* dde.n */, diff --git a/win/tcl.dsp b/win/tcl.dsp index e8b1a33..4f35cb3 100644 --- a/win/tcl.dsp +++ b/win/tcl.dsp @@ -364,7 +364,7 @@ SOURCE=..\doc\CrtObjCmd.3 # End Source File
# Begin Source File
-SOURCE=..\doc\CrtSlave.3
+SOURCE=..\doc\CrtAlias.3
# End Source File
# Begin Source File
|