mirror of
https://git.proxmox.com/git/qemu
synced 2025-07-03 05:02:18 +00:00
net: purge queued packets in tap_cleanup()
If tap has any packets queued at host_net_remove time, it needs to purge them in order to prevent a sent callback being invoked for it. Signed-off-by: Mark McLoughlin <markmc@redhat.com> Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
This commit is contained in:
parent
8cad55161c
commit
b9adce2c83
2
net.c
2
net.c
@ -1128,6 +1128,8 @@ static void tap_cleanup(VLANClientState *vc)
|
|||||||
{
|
{
|
||||||
TAPState *s = vc->opaque;
|
TAPState *s = vc->opaque;
|
||||||
|
|
||||||
|
qemu_purge_queued_packets(vc);
|
||||||
|
|
||||||
if (s->down_script[0])
|
if (s->down_script[0])
|
||||||
launch_script(s->down_script, s->down_script_arg, s->fd);
|
launch_script(s->down_script, s->down_script_arg, s->fd);
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user