bug-grep
[Top][All Lists]
Advanced

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

Re: [bug #33198] Incorrect bracket expression when parsing in ru_RU.KOI8


From: Jim Meyering
Subject: Re: [bug #33198] Incorrect bracket expression when parsing in ru_RU.KOI8-R (Russian locale)
Date: Tue, 03 May 2011 11:49:22 +0200

Dmitry V. Levin wrote:
> On Mon, May 02, 2011 at 07:20:15PM +0000, Jim Meyering wrote:
...
>> Thanks for the report.
>> however, I cannot reproduce the problem with grep-2.7 built from upstream
>> sources.  Nor can I reproduce it using the grep-2.7 that comes from Fedora
>> 15.
>>
>> To test it, I put these two lines in a file,
>>
>> #!/bin/sh
>> echo Пример| LC_ALL=ru_RU.KOI8-R grep -qE "[Пп]ример"; echo $?
>>
>> and then ran "bash FILE".  It always prints 1.
>> (Of course, I set PATH to select either /bin/grep or ./grep,
>> depending on which I'm testing).
>>
>> On that basis, I've closed this ticket.
>> If you have evidence that there's a real problem with the upstream sources,
>> feel free to reopen it.
>
> I confirm there is a bug, you just have to adjust the test case:
> $ echo Пример |iconv -tutf8 |LANG=ru_RU.utf8 grep -q "$(echo "[Пп]ример" 
> |iconv -tutf8)"; echo $?
> 0
> $ echo Пример |iconv -tkoi8r |LANG=ru_RU.koi8r grep -q "$(echo "[Пп]ример" 
> |iconv -tkoi8r)"; echo $?
> 1
> $ echo Sример |iconv -tkoi8r |LANG=ru_RU.koi8r grep -q "$(echo "[Ss]ример" 
> |iconv -tkoi8r)"; echo $?
> 0

Hi Dmitry,

Thanks for the clarification and for reopening that.
That is indeed a bug.
(actually I realized it right away and posted, but the
web form submission failed, and I noticed that only this morning)



reply via email to

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