unifying: Don't log a warning when an unknown report is parsed

Fixes: https://github.com/hughsie/fwupd/issues/151
This commit is contained in:
Richard Hughes 2017-07-07 13:41:49 +01:00
parent 8cb067d528
commit c633edc773
2 changed files with 8 additions and 2 deletions

View File

@ -498,6 +498,13 @@ lu_device_hidpp_transfer (LuDevice *device, LuHidppMsg *msg, GError **error)
if (!lu_device_hidpp_receive (device, msg_tmp, timeout, error))
return FALSE;
/* we don't know how to handle this report packet */
if (lu_hidpp_msg_get_payload_length (msg_tmp) == 0x0) {
g_debug ("HID++1.0 report 0x%02x has unknown length, ignoring",
msg_tmp->report_id);
continue;
}
if (!lu_hidpp_msg_is_error (msg_tmp, error))
return FALSE;

View File

@ -70,8 +70,7 @@ lu_hidpp_msg_get_payload_length (LuHidppMsg *msg)
return 0x2f;
if (msg->report_id == HIDPP_REPORT_NOTIFICATION)
return 0x08;
g_warning ("report 0x%02x unknown length", msg->report_id);
return 0x08;
return 0x0;
}
const gchar *