aboutsummaryrefslogtreecommitdiffstats
path: root/src/vnet/devices/virtio/virtio.c
diff options
context:
space:
mode:
authorDamjan Marion <damarion@cisco.com>2017-12-04 11:23:58 +0100
committerDamjan Marion <damarion@cisco.com>2017-12-04 11:24:53 +0100
commit7074961b48efaf932fef27f9879582ef202efef6 (patch)
tree15d4cf26b0cb4035b6866dbef97aa3137b4c3d0b /src/vnet/devices/virtio/virtio.c
parent04fee31f265b1d8b602bf336ef1df6c917cf18b2 (diff)
virtio: zero data structs in virtio_vring_init
Change-Id: I877cf1abb062a90f428c3ec0cab5c6e9dad0ca82 Signed-off-by: Damjan Marion <damarion@cisco.com>
Diffstat (limited to 'src/vnet/devices/virtio/virtio.c')
-rw-r--r--src/vnet/devices/virtio/virtio.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/vnet/devices/virtio/virtio.c b/src/vnet/devices/virtio/virtio.c
index 63ca6011a9e..7418673bbd1 100644
--- a/src/vnet/devices/virtio/virtio.c
+++ b/src/vnet/devices/virtio/virtio.c
@@ -62,9 +62,9 @@ virtio_vring_init (vlib_main_t * vm, virtio_if_t * vif, u16 idx, u16 sz)
{
clib_error_t *err = 0;
virtio_vring_t *vring;
- struct vhost_vring_state state;
- struct vhost_vring_addr addr;
- struct vhost_vring_file file;
+ struct vhost_vring_state state = { 0 };
+ struct vhost_vring_addr addr = { 0 };
+ struct vhost_vring_file file = { 0 };
clib_file_t t = { 0 };
int i;