uhci: Fix null pointer dereference.

Found by: Coverity scan.
This commit is contained in:
Vladimir Serbinenko 2015-01-24 20:38:12 +01:00
parent 3661261fe1
commit 9ff9d5a54e

View file

@ -625,9 +625,7 @@ grub_uhci_check_transfer (grub_usb_controller_t dev,
return GRUB_USB_ERR_NONE; return GRUB_USB_ERR_NONE;
} }
grub_dprintf ("uhci", "t status=0x%02x\n", errtd->ctrl_status); if (errtd && !(errtd->ctrl_status & (1 << 23)))
if (!(errtd->ctrl_status & (1 << 23)))
{ {
grub_usb_err_t err = GRUB_USB_ERR_NONE; grub_usb_err_t err = GRUB_USB_ERR_NONE;