summaryrefslogtreecommitdiffstats
path: root/generic/tclCmdMZ.c
diff options
context:
space:
mode:
authordkf <donal.k.fellows@manchester.ac.uk>2012-01-22 12:13:17 (GMT)
committerdkf <donal.k.fellows@manchester.ac.uk>2012-01-22 12:13:17 (GMT)
commitb96fd52bcba33e8f663042cd073454aa954723a8 (patch)
treef8e7b570982f2b528ff94f6e3389ec228acc95c0 /generic/tclCmdMZ.c
parent7a28ca58d78656d8cac01cff71138f393cb52b5d (diff)
parent4aed2bc2cd16fef4ffe748ec35725686038a4fbb (diff)
downloadtcl-b96fd52bcba33e8f663042cd073454aa954723a8.zip
tcl-b96fd52bcba33e8f663042cd073454aa954723a8.tar.gz
tcl-b96fd52bcba33e8f663042cd073454aa954723a8.tar.bz2
merge from 8.5 main branch
Diffstat (limited to 'generic/tclCmdMZ.c')
-rw-r--r--generic/tclCmdMZ.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/generic/tclCmdMZ.c b/generic/tclCmdMZ.c
index 60a9414..ab673d5 100644
--- a/generic/tclCmdMZ.c
+++ b/generic/tclCmdMZ.c
@@ -264,7 +264,7 @@ Tcl_RegexpObjCmd(
* start of the string unless the previous character is a newline.
*/
- if ((offset == 0) || ((offset > 0) &&
+ if ((offset == 0) || ((offset > 0) && (offset < stringLength) &&
(Tcl_GetUniChar(objPtr, offset-1) == (Tcl_UniChar)'\n'))) {
eflags = 0;
} else {