diff options
author | jan.nijtmans <nijtmans@users.sourceforge.net> | 2013-01-10 11:31:02 (GMT) |
---|---|---|
committer | jan.nijtmans <nijtmans@users.sourceforge.net> | 2013-01-10 11:31:02 (GMT) |
commit | 424ff3b68c8ecc22d0f8de08c13bbea69036e334 (patch) | |
tree | db2cf9676505d741b2180ad7b931c8b00dbd82b4 /generic/tclThreadTest.c | |
parent | ae15ddb2ebc7381aa51cd18473d4d5408e05e012 (diff) | |
parent | 4cc39eb0353b0c510d6e501b0ea911b913e31e29 (diff) | |
download | tcl-424ff3b68c8ecc22d0f8de08c13bbea69036e334.zip tcl-424ff3b68c8ecc22d0f8de08c13bbea69036e334.tar.gz tcl-424ff3b68c8ecc22d0f8de08c13bbea69036e334.tar.bz2 |
merge novem
Diffstat (limited to 'generic/tclThreadTest.c')
-rw-r--r-- | generic/tclThreadTest.c | 9 |
1 files changed, 4 insertions, 5 deletions
diff --git a/generic/tclThreadTest.c b/generic/tclThreadTest.c index d642097..e718d34 100644 --- a/generic/tclThreadTest.c +++ b/generic/tclThreadTest.c @@ -61,8 +61,8 @@ static ThreadSpecificData *threadList = NULL; * "thread create" Tcl command or the ThreadCreate() C function. */ -typedef struct { - const char *script; /* The Tcl command this thread should +typedef struct ThreadCtrl { + const char *script; /* The Tcl command this thread should * execute */ int flags; /* Initial value of the "flags" field in the * ThreadSpecificData structure for the new @@ -229,8 +229,8 @@ ThreadObjCmd( Tcl_WrongNumArgs(interp, 1, objv, "option ?arg ...?"); return TCL_ERROR; } - if (Tcl_GetIndexFromObj(interp, objv[1], threadOptions, "option", 0, - &option) != TCL_OK) { + if (Tcl_GetIndexFromObjStruct(interp, objv[1], threadOptions, + sizeof(char *), "option", 0, &option) != TCL_OK) { return TCL_ERROR; } @@ -513,7 +513,6 @@ ThreadCreate( TCL_THREAD_STACK_DEFAULT, joinable) != TCL_OK) { Tcl_MutexUnlock(&threadMutex); Tcl_AppendResult(interp, "can't create a new thread", NULL); - ckfree(ctrl.script); return TCL_ERROR; } |