On 11/02/2015 17:37, Gerd Hoffmann wrote: > vnc_display_local_addr will not be called with an invalid display id. > Add assert() to silence coverity warning about a null pointer dereference. > > Signed-off-by: Gerd Hoffmann <kra...@redhat.com> > --- > ui/vnc.c | 1 + > 1 file changed, 1 insertion(+) > > diff --git a/ui/vnc.c b/ui/vnc.c > index e291987..25ba340 100644 > --- a/ui/vnc.c > +++ b/ui/vnc.c > @@ -3252,6 +3252,7 @@ char *vnc_display_local_addr(const char *id) > { > VncDisplay *vs = vnc_display_find(id); > > + assert(vs); > return vnc_socket_local_addr("%s:%s", vs->lsock); > } > >
If you want, I can just silence the warning in Coverity. Paolo