aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--hw/usb/dev-network.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/hw/usb/dev-network.c b/hw/usb/dev-network.c
index 18669917f5..9be3a64006 100644
--- a/hw/usb/dev-network.c
+++ b/hw/usb/dev-network.c
@@ -1310,6 +1310,10 @@ static int usbnet_can_receive(NetClientState *nc)
{
USBNetState *s = qemu_get_nic_opaque(nc);
+ if (!s->dev.config) {
+ return 0;
+ }
+
if (is_rndis(s) && s->rndis_state != RNDIS_DATA_INITIALIZED) {
return 1;
}