diff options
author | Vladimir Sementsov-Ogievskiy <vsementsov@yandex-team.ru> | 2025-07-16 10:28:53 +0300 |
---|---|---|
committer | Jason Wang <jasowang@redhat.com> | 2025-07-21 10:21:28 +0800 |
commit | 3f9f6299a1bc46ff462142c7398a5953e3640cc2 (patch) | |
tree | 6350f1f82fa890114bf7860b5d6f9db00194a8d3 /scripts/tracetool/backend/simple.py | |
parent | e82989544e38062beeeaad88c175afbeed0400f8 (diff) | |
download | qemu-3f9f6299a1bc46ff462142c7398a5953e3640cc2.zip qemu-3f9f6299a1bc46ff462142c7398a5953e3640cc2.tar.gz qemu-3f9f6299a1bc46ff462142c7398a5953e3640cc2.tar.bz2 |
net/tap: drop too small packets
Theoretically tap_read_packet() may return size less than
s->host_vnet_hdr_len, and next, we'll work with negative size
(in case of !s->using_vnet_hdr). Let's avoid it.
Don't proceed with size == s->host_vnet_hdr_len as well in case
of !s->using_vnet_hdr, it doesn't make sense.
Tested-by: Lei Yang <leiyang@redhat.com>
Signed-off-by: Vladimir Sementsov-Ogievskiy <vsementsov@yandex-team.ru>
Signed-off-by: Jason Wang <jasowang@redhat.com>
Diffstat (limited to 'scripts/tracetool/backend/simple.py')
0 files changed, 0 insertions, 0 deletions