summaryrefslogtreecommitdiffstats
path: root/generic
diff options
context:
space:
mode:
authorfvogel <fvogelnew1@free.fr>2015-10-09 19:20:13 (GMT)
committerfvogel <fvogelnew1@free.fr>2015-10-09 19:20:13 (GMT)
commitbefbed0e52d43e9fe81b8b577dd2dcf7ee01af03 (patch)
tree6efc7dab682c9f017b5b5d925089915c70383093 /generic
parent8b801ee48d016fb44dee5bcc272a19b43d180d6c (diff)
parent687cdd2ef3948e5acf8a888de2578fa194958bcf (diff)
downloadtk-befbed0e52d43e9fe81b8b577dd2dcf7ee01af03.zip
tk-befbed0e52d43e9fe81b8b577dd2dcf7ee01af03.tar.gz
tk-befbed0e52d43e9fe81b8b577dd2dcf7ee01af03.tar.bz2
Fixed bug [2262711fff] - Regexp search fails with Unicode and elide
Diffstat (limited to 'generic')
-rw-r--r--generic/tkText.c6
1 files changed, 5 insertions, 1 deletions
diff --git a/generic/tkText.c b/generic/tkText.c
index f023509..cb89218 100644
--- a/generic/tkText.c
+++ b/generic/tkText.c
@@ -4196,7 +4196,11 @@ TextSearchFoundMatch(
matchOffset += Tcl_NumUtfChars(segPtr->body.chars, -1);
}
} else {
- leftToScan -= segPtr->size;
+ if (searchSpecPtr->exact) {
+ leftToScan -= segPtr->size;
+ } else {
+ leftToScan -= Tcl_NumUtfChars(segPtr->body.chars, -1);
+ }
}
curIndex.byteIndex += segPtr->size;
}