diff options
author | dgp <dgp@users.sourceforge.net> | 2013-04-11 19:36:37 (GMT) |
---|---|---|
committer | dgp <dgp@users.sourceforge.net> | 2013-04-11 19:36:37 (GMT) |
commit | 87dc28ad0ec271d380acc051908672eb9a3adb43 (patch) | |
tree | 4dea2215642cc19c35fd70cf3a350bad6195c516 /generic/tclInterp.c | |
parent | 2816004e58ac0da7bde02b0159b164e54c04ab6a (diff) | |
download | tcl-87dc28ad0ec271d380acc051908672eb9a3adb43.zip tcl-87dc28ad0ec271d380acc051908672eb9a3adb43.tar.gz tcl-87dc28ad0ec271d380acc051908672eb9a3adb43.tar.bz2 |
More revisions let multi-interp test case work, but at cost of panics
and segfaults. Pushing the NRE-envelope.
Diffstat (limited to 'generic/tclInterp.c')
-rw-r--r-- | generic/tclInterp.c | 18 |
1 files changed, 17 insertions, 1 deletions
diff --git a/generic/tclInterp.c b/generic/tclInterp.c index ac51d9d..e9ed790 100644 --- a/generic/tclInterp.c +++ b/generic/tclInterp.c @@ -279,6 +279,7 @@ static void DeleteScriptLimitCallback(ClientData clientData); static void RunLimitHandlers(LimitHandler *handlerPtr, Tcl_Interp *interp); static void TimeLimitCallback(ClientData clientData); +static Tcl_NRPostProc NRPostInvokeHidden; /* *---------------------------------------------------------------------- @@ -3056,7 +3057,9 @@ SlaveInvokeHidden( Tcl_Release(slaveInterp); return TclNRInvoke(NULL, slaveInterp, objc, objv); } else { - result = TclObjInvoke(slaveInterp, objc, objv, TCL_INVOKE_HIDDEN); + Tcl_NRAddCallback(interp, NRPostInvokeHidden, slaveInterp, + NULL, NULL, NULL); + return TclNRInvoke(NULL, slaveInterp, objc, objv); } } else { Namespace *nsPtr, *dummy1, *dummy2; @@ -3076,6 +3079,19 @@ SlaveInvokeHidden( Tcl_Release(slaveInterp); return result; } + +static int +NRPostInvokeHidden( + ClientData data[], + Tcl_Interp *interp, + int result) +{ + Tcl_Interp *slaveInterp = (Tcl_Interp *)data[0]; + + Tcl_TransferResult(slaveInterp, result, interp); + Tcl_Release(slaveInterp); + return result; +} /* *---------------------------------------------------------------------- |