develooper Front page | perl.perl5.porters | Postings from April 2014

[perl #121712] [PATCH] Coverity: regcomp.c etc.

Thread Previous
From:
Tony Cook via RT
Date:
April 29, 2014 00:32
Subject:
[perl #121712] [PATCH] Coverity: regcomp.c etc.
Message ID:
rt-4.0.18-14985-1398731550-1683.121712-15-0@perl.org
On Wed Apr 23 16:59:42 2014, jhi wrote:
> On Wednesday-201404-23, 15:06, Hugo van der Sanden via RT wrote:
> > There seems also to be a copy/paste in the comments:
> > +#  define REG_EXTFLAGS_NAME_SIZE $REG_EXTFLAGS_NAME_SIZE /*
> > sizeof(PL_reg_intflags_name) */
> > +#  define REG_EXTFLAGS_NAME_SIZE 32 /* sizeof(PL_reg_intflags_name)
> > */
> >
> > I assume both should s/int/ext/.
> >
> > Hugo
> 
> The updated patch attached.
> 
> It also includes the suggestion to use assert(), though I went ahead
> and
> used the new shiny ASSUME() -- please correct as appropriate, I might
> have misunderstood ASSUME.
> 
> (Further change from the earlier incarnation is that the new symbols
> are made visible under DEBUGGING, not PERL_EXT_RE_BUILD.)

+#ifdef DEBUGGING
+#  define REG_INTFLAGS_NAME_SIZE 14 /* sizeof(PL_reg_intflags_name) */
+#endif

It's not really sizeof(), but the element count.

Outside of that I think it's good.

Tony


---
via perlbug:  queue: perl5 status: open
https://rt.perl.org/Ticket/Display.html?id=121712

Thread Previous


nntp.perl.org: Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at ask@perl.org | Group listing | About