Somehow it seems that rlength in do_match() gets a bad value inside the
MSB_SUPPORT code ... without really understanding what is going on, it
seems that the following patch seems to address the special case mentioned
previously.
Sorry for submitting a patch when I do not understand thorougly the code
.. but I thought it may still be useful as a hint ...
Hope this helps,
Berni
=== modified file 'builtin.c'
--- builtin.c
+++ builtin.c
@@ -2022,7 +2022,9 @@
#ifdef MBS_SUPPORT
if (gawk_mb_cur_max > 1) {
t1 = str2wstr(t1, & wc_indices);
- rlength = wc_indices[rstart + rlength - 1] -
wc_indices[ rstart] + 1;
+ if (rlength > 0) {
+ rlength = wc_indices[rstart + rlength - 1] -
wc_indices[rstart] + 1;
+ }
rstart = wc_indices[rstart];
}
#endif
--
To UNSUBSCRIBE, email to [EMAIL PROTECTED]
with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]