On Tue, Sep 10, 2024 at 03:38:45AM -0600, Claudio Jeker wrote:
> CVSROOT:      /cvs
> Module name:  src
> Changes by:   clau...@cvs.openbsd.org 2024/09/10 03:38:45
> 
> Modified files:
>       usr.sbin/bgpd  : rde.c rde_attr.c rde_sets.c 
> 
> Log message:
> Be more careful with aspath that have 0 length (aka the empty AS_PATH).
> 
> Again malloc(0) is not portable and calling memcpy with a NULL pointer
> and a 0 length is not allowed by the C standard.
> 

This includes a similar check in rde_sets.c which just skips set_add if
the number of elements is 0 and on top of this the rde.c change ensures
that the imsg size of IMSG_RECONF_AS_SET_ITEMS includes at least one
object and is object sized.

-- 
:wq Claudio

Reply via email to