diff options
author | rjohnson <rjohnson@noemail.net> | 1998-10-13 18:44:15 (GMT) |
---|---|---|
committer | rjohnson <rjohnson@noemail.net> | 1998-10-13 18:44:15 (GMT) |
commit | 0728c98865e74d0166ad157308c0b19f8bd0d679 (patch) | |
tree | 2f156e604f9e353b3135cfa37592af5cec5a76f5 /generic/tclCmdIL.c | |
parent | b26da50c3bd52e31ce8372c1b21d54085ccb7ad2 (diff) | |
download | tcl-0728c98865e74d0166ad157308c0b19f8bd0d679.zip tcl-0728c98865e74d0166ad157308c0b19f8bd0d679.tar.gz tcl-0728c98865e74d0166ad157308c0b19f8bd0d679.tar.bz2 |
Fixed bug in "info complete" - it did not handle NULLs correctly.
FossilOrigin-Name: 5ae085bcc21de9de1f5e59b1e85bc8909c02ac60
Diffstat (limited to 'generic/tclCmdIL.c')
-rw-r--r-- | generic/tclCmdIL.c | 8 |
1 files changed, 3 insertions, 5 deletions
diff --git a/generic/tclCmdIL.c b/generic/tclCmdIL.c index 470d291..a1e6894 100644 --- a/generic/tclCmdIL.c +++ b/generic/tclCmdIL.c @@ -13,7 +13,7 @@ * See the file "license.terms" for information on usage and redistribution * of this file, and for a DISCLAIMER OF ALL WARRANTIES. * - * RCS: @(#) $Id: tclCmdIL.c,v 1.7 1998/09/14 18:39:57 stanton Exp $ + * RCS: @(#) $Id: tclCmdIL.c,v 1.8 1998/10/13 18:44:16 rjohnson Exp $ */ #include "tclInt.h" @@ -762,19 +762,17 @@ InfoCompleteCmd(dummy, interp, objc, objv) int objc; /* Number of arguments. */ Tcl_Obj *CONST objv[]; /* Argument objects. */ { - char *command; - if (objc != 3) { Tcl_WrongNumArgs(interp, 2, objv, "command"); return TCL_ERROR; } - command = Tcl_GetStringFromObj(objv[2], (int *) NULL); - if (Tcl_CommandComplete(command)) { + if (TclObjCommandComplete(objv[2])) { Tcl_SetIntObj(Tcl_GetObjResult(interp), 1); } else { Tcl_SetIntObj(Tcl_GetObjResult(interp), 0); } + return TCL_OK; } |