From 41d44a815a68a2618805c1d670b4ff93091a99d8 Mon Sep 17 00:00:00 2001 From: Antti Palosaari Date: Sun, 1 Apr 2012 11:06:23 -0300 Subject: [PATCH] [media] af9035: add missing error check Signed-off-by: Antti Palosaari Signed-off-by: Mauro Carvalho Chehab --- drivers/media/dvb/dvb-usb/af9035.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/drivers/media/dvb/dvb-usb/af9035.c b/drivers/media/dvb/dvb-usb/af9035.c index 01dee02..dc0a49a 100644 --- a/drivers/media/dvb/dvb-usb/af9035.c +++ b/drivers/media/dvb/dvb-usb/af9035.c @@ -400,6 +400,8 @@ static int af9035_download_firmware(struct usb_device *udev, /* download begin packet */ req.cmd = CMD_FW_DL_BEGIN; ret = af9035_ctrl_msg(udev, &req); + if (ret < 0) + goto err; /* download firmware packet(s) */ for (j = HDR_SIZE + hdr_data_len; j > 0; j -= MAX_DATA) { -- 2.7.4