[ovs-dev] null deref in build_ipam?

Ben Pfaff blp at ovn.org
Tue May 30 17:12:35 UTC 2017


On Tue, May 30, 2017 at 09:59:25AM -0700, Guru Shetty wrote:
> On 26 May 2017 at 22:46, Ben Pfaff <blp at ovn.org> wrote:
> 
> > Coverity points out the following code in build_ipam() in ovn-northd.c:
> >
> >                 if (is_dynamic_lsp_address(nbsp->addresses[j])
> >                     && !nbsp->dynamic_addresses) {
> >                     if (!ipam_allocate_addresses(od, op,
> > nbsp->addresses[j])
> >                         || !extract_lsp_addresses(nbsp->dynamic_addresses,
> >                                         &op->lsp_addrs[op->n_lsp_addrs]))
> > {
> >
> 
> I think the intention is that ipam_allocate_addresses() would only return
> success if nbsp->dynamic_addresses is allocated. So there should no null
> deref.

Oh, haha, thanks, I see that now.  False alarm.


More information about the dev mailing list