Jason Wang c546ecf27d virtio-net: check the existence of peer before accessing vDPA config
We try to check whether a peer is VDPA in order to get config from
there - with no peer, this leads to a NULL
pointer dereference. Add a check before trying to access the peer
type. No peer means not VDPA.

Fixes: 108a64818e69b ("vhost-vdpa: introduce vhost-vdpa backend")
Cc: Cindy Lu <lulu@redhat.com>
Tested-by: Cornelia Huck <cohuck@redhat.com>
Reviewed-by: Cornelia Huck <cohuck@redhat.com>
Signed-off-by: Jason Wang <jasowang@redhat.com>
2020-07-28 16:57:58 +08:00
..
2020-07-10 15:18:09 +02:00
2020-07-17 11:39:46 -05:00
2020-07-10 15:18:09 +02:00
2020-07-27 11:09:25 +10:00
2020-07-16 10:20:12 +02:00