qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

RE: [PATCH] net/colo.c: Fix the pointer issuse reported by Coverity.


From: Zhang, Chen
Subject: RE: [PATCH] net/colo.c: Fix the pointer issuse reported by Coverity.
Date: Fri, 5 Aug 2022 09:22:56 +0000


> -----Original Message-----
> From: Peter Maydell <peter.maydell@linaro.org>
> Sent: Friday, August 5, 2022 4:53 PM
> To: Zhang, Chen <chen.zhang@intel.com>
> Cc: Jason Wang <jasowang@redhat.com>; Li Zhijian <lizhijian@fujitsu.com>;
> qemu-dev <qemu-devel@nongnu.org>
> Subject: Re: [PATCH] net/colo.c: Fix the pointer issuse reported by Coverity.
> 
> On Fri, 5 Aug 2022 at 06:56, Zhang, Chen <chen.zhang@intel.com> wrote:
> >
> >
> >
> > > -----Original Message-----
> > > From: Jason Wang <jasowang@redhat.com> I wonder under which case
> we
> > > can see data == NULL?
> > >
> > > AFAIK, data is either dup via packet_new() or assigned to a pointer
> > > to the buf in packet_new_nocopy().
> >
> > Yes, you are right. I just checked it for hint of bugs.
> > Do you think no need to do it?
> 
> If you think it is a "should never happen unless QEMU is buggy" case, then
> assert(data).

OK, I will change it to assert() in V2.

Thanks
Chen

> 
> thanks
> -- PMM

reply via email to

[Prev in Thread] Current Thread [Next in Thread]