On Mon, Jun 29, 2026 at 08:35:59AM +0930, Alan Modra wrote:
> On Sun, Jun 28, 2026 at 08:29:42PM +0200, Fabrice Derepas wrote:
> > Component: libiberty / cp-demangle.c
> 
> libiberty is owned by the gcc project.
> 
> > Option B: perform the addition safely in `d_compact_number`:
> > ```c
> > /* d_compact_number(), line 3269 */
> > -    num = d_number (di) + 1;
> > +    num = d_number (di);
> > +    if (num == INT_MAX)
> > +      return -1;
> > +    num = num + 1;
> 
> Or just write
>    num = d_number (di) + 1u;
> Wrap-around will be caught by the < 0 test following this code.

I've pushed this patch to both gcc and binutils.

-- 
Alan Modra

Reply via email to