diff options
author | hobbs <hobbs@noemail.net> | 2002-02-02 00:20:53 (GMT) |
---|---|---|
committer | hobbs <hobbs@noemail.net> | 2002-02-02 00:20:53 (GMT) |
commit | 6cc100dbad0d2f3e1580a2fd63c5af602086e8df (patch) | |
tree | 80a0054cf92d3d10974f4a1ea5676eacf1bf2bbe | |
parent | 526b854b63483cff0a7543e6037a6e5e5ea75166 (diff) | |
download | tcl-6cc100dbad0d2f3e1580a2fd63c5af602086e8df.zip tcl-6cc100dbad0d2f3e1580a2fd63c5af602086e8df.tar.gz tcl-6cc100dbad0d2f3e1580a2fd63c5af602086e8df.tar.bz2 |
* generic/tclCmdMZ.c (Tcl_RegexpObjCmd): handle quirky about case
earlier to avoid shimmering problem.
FossilOrigin-Name: 8dd6f681a36c54cde97eef23fcde8c6722ae8b0a
-rw-r--r-- | ChangeLog | 5 | ||||
-rw-r--r-- | generic/tclCmdMZ.c | 20 |
2 files changed, 17 insertions, 8 deletions
@@ -1,3 +1,8 @@ +2002-02-01 Jeff Hobbs <jeffh@ActiveState.com> + + * generic/tclCmdMZ.c (Tcl_RegexpObjCmd): handle quirky about case + earlier to avoid shimmering problem. + 2002-02-01 Andreas Kupries <andreas_kupries@users.sourceforge.net> * tests/io.test: io-39.22 split into two tests, one platform diff --git a/generic/tclCmdMZ.c b/generic/tclCmdMZ.c index e0cacab..425ef3a 100644 --- a/generic/tclCmdMZ.c +++ b/generic/tclCmdMZ.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: tclCmdMZ.c,v 1.56 2002/01/21 16:15:03 dgp Exp $ + * RCS: @(#) $Id: tclCmdMZ.c,v 1.57 2002/02/02 00:20:54 hobbs Exp $ */ #include "tclInt.h" @@ -250,6 +250,17 @@ Tcl_RegexpObjCmd(dummy, interp, objc, objv) } /* + * Handle the odd about case separately. + */ + if (about) { + regExpr = Tcl_GetRegExpFromObj(interp, objv[0], cflags); + if ((regExpr == NULL) || (TclRegAbout(interp, regExpr) < 0)) { + return TCL_ERROR; + } + return TCL_OK; + } + + /* * Get the length of the string that we are matching against so * we can do the termination test for -all matches. Do this before * getting the regexp to avoid shimmering problems. @@ -262,13 +273,6 @@ Tcl_RegexpObjCmd(dummy, interp, objc, objv) return TCL_ERROR; } - if (about) { - if (TclRegAbout(interp, regExpr) < 0) { - return TCL_ERROR; - } - return TCL_OK; - } - if (offset > 0) { /* * Add flag if using offset (string is part of a larger string), |