[PATCH] eal: fix pointer add/sub macros for large offsets values
Bruce Richardson
bruce.richardson at intel.com
Mon Sep 14 11:05:51 CEST 2026
On Mon, Sep 14, 2026 at 08:29:42AM +0000, Konstantin Ananyev wrote:
>
>
> > The macros for adding or subtracting from pointers cast the pointer type
> > to uintptr_t before doing the arithmetic. However, for 32-bit builds, if
> > the value being added or subtracted is larger than uintptr_t, then we
> > get errors when casting back to "void *" type.
>
> But probably error here in such case is a good thing, as it flags an overflow?
> Can't user explicitly convert x then to 32-bit type, if that was an intention?
>
Fair point, hadn't thought of that! Let me mark this as rejected so.
/Bruce
More information about the stable
mailing list