mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-30 03:27:44 -04:00
vhost_net: add a missing error return
We accidentally left out this error return so it leads to some use after
free bugs later on.
Fixes: 0a0be13b8f ("vhost_net: batch submitting XDP buffers to underlayer sockets")
Signed-off-by: Dan Carpenter <[email protected]>
Acked-by: Michael S. Tsirkin <[email protected]>
Acked-by: Jason Wang <[email protected]>
Signed-off-by: David S. Miller <[email protected]>
This commit is contained in:
parent
1ba2a720da
commit
8a1aff144d
1 changed files with 1 additions and 0 deletions
|
|
@ -1244,6 +1244,7 @@ static int vhost_net_open(struct inode *inode, struct file *f)
|
|||
kfree(vqs);
|
||||
kvfree(n);
|
||||
kfree(queue);
|
||||
return -ENOMEM;
|
||||
}
|
||||
n->vqs[VHOST_NET_VQ_TX].xdp = xdp;
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue