Message ID | 20191112092228.15800-3-hverkuil-cisco@xs4all.nl (mailing list archive) |
---|---|
State | New, archived |
Headers | show |
Series | Fix various syzbot errors | expand |
On Tue, Nov 12, 2019 at 10:22:25AM +0100, Hans Verkuil wrote: > The act_len variable was uninitialized, leading to a syzbot > error. > > Syzbot link: > > https://syzkaller.appspot.com/bug?extid=9d42b7773d2fecd983ab > > Signed-off-by: Hans Verkuil <hverkuil-cisco@xs4all.nl> > Reported-and-tested-by: syzbot+9d42b7773d2fecd983ab@syzkaller.appspotmail.com > CC: Sean Young <sean@mess.org> This is the same as: https://patchwork.linuxtv.org/patch/59986/ Sean > --- > drivers/media/usb/dvb-usb/af9005.c | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/drivers/media/usb/dvb-usb/af9005.c b/drivers/media/usb/dvb-usb/af9005.c > index ac93e88d7038..89b4b5d84cdf 100644 > --- a/drivers/media/usb/dvb-usb/af9005.c > +++ b/drivers/media/usb/dvb-usb/af9005.c > @@ -554,7 +554,7 @@ static int af9005_boot_packet(struct usb_device *udev, int type, u8 *reply, > u8 *buf, int size) > { > u16 checksum; > - int act_len, i, ret; > + int act_len = 0, i, ret; > > memset(buf, 0, size); > buf[0] = (u8) (FW_BULKOUT_SIZE & 0xff); > -- > 2.24.0
diff --git a/drivers/media/usb/dvb-usb/af9005.c b/drivers/media/usb/dvb-usb/af9005.c index ac93e88d7038..89b4b5d84cdf 100644 --- a/drivers/media/usb/dvb-usb/af9005.c +++ b/drivers/media/usb/dvb-usb/af9005.c @@ -554,7 +554,7 @@ static int af9005_boot_packet(struct usb_device *udev, int type, u8 *reply, u8 *buf, int size) { u16 checksum; - int act_len, i, ret; + int act_len = 0, i, ret; memset(buf, 0, size); buf[0] = (u8) (FW_BULKOUT_SIZE & 0xff);
The act_len variable was uninitialized, leading to a syzbot error. Syzbot link: https://syzkaller.appspot.com/bug?extid=9d42b7773d2fecd983ab Signed-off-by: Hans Verkuil <hverkuil-cisco@xs4all.nl> Reported-and-tested-by: syzbot+9d42b7773d2fecd983ab@syzkaller.appspotmail.com CC: Sean Young <sean@mess.org> --- drivers/media/usb/dvb-usb/af9005.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)