[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[bug-grep] [bugs #12210] EGexecute() fails to find matches on (exact &&

From: anonymous
Subject: [bug-grep] [bugs #12210] EGexecute() fails to find matches on (exact && match_icase)
Date: Sat, 5 Mar 2005 17:32:14 +0000
User-agent: Mozilla/5.0 (X11; U; Linux i686; rv:1.7.3) Gecko/20040914 Firefox/0.10

Follow-up Comment #11, bugs #12210 (project grep):

I might have been too cryptic.

The for .. tolower loop is "required" when not using multibyte strings
(MBS_SUPPORT = 0 or MB_CUR_MAX = 1), and mimics the for .. towlower loop in

The reason I discovered today is that in Gcompile we are not calling the
regex external api (regcomp) passing the REG_ICASE in the cflags, but we're
calling re_compile_pattern internal function directly.

This way we are skipping the code in regex.c which deals with REG_ICASE at
the beginning of regcomp.

There are two solutions I see:

1) assign to the translate member directly (as I have done in the patch), but
fix it to do it only if not using multibyte strings (as speedup). Downside: no
guarantee that will work in the future, as it is not something regex exposes.

2) redesign the entire thing to use the documented regex interfaces.

I would suggest going 1) for the short term, and 2) as a long term goal.

I will fix my patch to avoid doing the unnecessary assignment to translate
when using multibyte strings.

I know my patch is far too big (it was not intended primarily for this goal),
I will prepare a more focused one when I have it fixed.


This item URL is:


  Message sent via/by Savannah

reply via email to

[Prev in Thread] Current Thread [Next in Thread]