summaryrefslogtreecommitdiffstats
path: root/src/vnet/devices/virtio
diff options
context:
space:
mode:
authorVladislav Grishenko <themiron@yandex-team.ru>2021-11-20 14:52:53 +0500
committerAndrew Yourtchenko <ayourtch@gmail.com>2022-08-31 15:26:19 +0000
commit62fc78761c2a1e023f9483a54776cc66332ecacc (patch)
tree4178908d8c995f8eb8c5c239e9f985d8fbe28e36 /src/vnet/devices/virtio
parent6556a9944f291851a583e86ff7d8613e25c7f39e (diff)
gso: zero-initialize gho struct
It may contain garbage in debug builds resulting in wrong gho detected flags and offsets. Type: fix Signed-off-by: Vladislav Grishenko <themiron@yandex-team.ru> Change-Id: Ia79633262185016f527e7dc6c67334cda6f055f2
Diffstat (limited to 'src/vnet/devices/virtio')
-rw-r--r--src/vnet/devices/virtio/device.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/src/vnet/devices/virtio/device.c b/src/vnet/devices/virtio/device.c
index 4e4f899540f..0ae41141a5a 100644
--- a/src/vnet/devices/virtio/device.c
+++ b/src/vnet/devices/virtio/device.c
@@ -109,6 +109,7 @@ virtio_tx_trace (vlib_main_t *vm, vlib_node_runtime_t *node, vlib_buffer_t *b0,
t = vlib_add_trace (vm, node, b0, sizeof (t[0]));
t->sw_if_index = vnet_buffer (b0)->sw_if_index[VLIB_TX];
t->buffer_index = bi;
+ clib_memset (&t->gho, 0, sizeof (t->gho));
if (is_tun)
{
int is_ip4 = 0, is_ip6 = 0;