steelseries: Ensure device is closed if it returns an invalid packet

This commit is contained in:
Richard Hughes 2017-05-08 12:43:17 +01:00
parent 2bdc588112
commit b0c65749fc

View File

@ -119,6 +119,7 @@ fu_plugin_steelseries_device_added_cb (GUsbContext *ctx,
}
if (actual_len != 32) {
g_warning ("only read %" G_GSIZE_FORMAT "bytes", actual_len);
g_usb_device_close (usb_device, NULL);
return;
}