GNU bug report logs - #47264
RFE: pcre2 support

Previous Next

Package: grep;

Reported by: Jaroslav Skarvada <jskarvad <at> redhat.com>

Date: Fri, 19 Mar 2021 15:23:01 UTC

Severity: wishlist

Merged with 22345, 40395

Done: Paul Eggert <eggert <at> cs.ucla.edu>

Bug is archived. No further changes may be made.

Full log


Message #93 received at 47264 <at> debbugs.gnu.org (full text, mbox):

From: Carlo Marcelo Arenas Belón <carenas <at> gmail.com>
To: Paul Eggert <eggert <at> cs.ucla.edu>
Cc: Jaroslav Skarvada <jskarvad <at> redhat.com>, 47264 <at> debbugs.gnu.org
Subject: Re: bug#47264: [PATCH v2] pcre: migrate to pcre2
Date: Mon, 15 Nov 2021 16:11:19 -0800
[Message part 1 (text/plain, inline)]
On Mon, Nov 15, 2021 at 03:24:41PM -0800, Paul Eggert wrote:
> On 11/15/21 12:49, Carlo Marcelo Arenas Belón wrote:
> 
> > Apologies, I realize it is difficult to talk about code in abstract when
> > not inlined, but I think it will better addressed by "fixing" it as shown
> > in the attached patch.
> 
> That patch isn't right, because the relevant code inside libpcre2 uses
> size_t, not PCRE2_SIZE and that means our hacky workaround should use
> SIZE_MAX, not PCRE2_SIZE_MAX, so that it's consistent with libpcre2's
> internals.

You are correct, got confused by the changes going to PCRE2_SIZE -> idx, and
should had check, thanks for catching this.

Hopefully the next patch (which I was planning to do with some of the
cleanup you beat me to), will at least clear some possible future valgrind
complain.

> Of course this is all academic on all existing platforms, since IDX_MAX is
> way less than SIZE_MAX.

Agree, and frankly I still think it will be better if IDX_MAX would be used
unconditionally instead.

Carlo
[0001-pcre-only-make-tables-when-needed-and-make-them-alwa.patch (text/plain, attachment)]

This bug report was last modified 3 years and 184 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.