Re: [PATCH v2] usb: storage: initialize variable

2020-08-24 Thread Alan Stern
On Mon, Aug 24, 2020 at 02:31:01PM -0700, Tom Rix wrote: > > On 8/24/20 2:18 PM, Vito Caputo wrote: > > On Mon, Aug 24, 2020 at 02:10:27PM -0700, t...@redhat.com wrote: > >> From: Tom Rix > >> > >> clang static analysis reports this representative problem > >> > >> transport.c:495:15: warning:

Re: [PATCH v2] usb: storage: initialize variable

2020-08-24 Thread Alan Stern
On Mon, Aug 24, 2020 at 02:18:39PM -0700, Vito Caputo wrote: > On Mon, Aug 24, 2020 at 02:10:27PM -0700, t...@redhat.com wrote: > > From: Tom Rix > > > > clang static analysis reports this representative problem > > > > transport.c:495:15: warning: Assigned value is garbage or > > undefined >

Re: [PATCH v2] usb: storage: initialize variable

2020-08-24 Thread Tom Rix
On 8/24/20 2:18 PM, Vito Caputo wrote: > On Mon, Aug 24, 2020 at 02:10:27PM -0700, t...@redhat.com wrote: >> From: Tom Rix >> >> clang static analysis reports this representative problem >> >> transport.c:495:15: warning: Assigned value is garbage or >> undefined >> length_left -=

Re: [PATCH v2] usb: storage: initialize variable

2020-08-24 Thread Vito Caputo
On Mon, Aug 24, 2020 at 02:10:27PM -0700, t...@redhat.com wrote: > From: Tom Rix > > clang static analysis reports this representative problem > > transport.c:495:15: warning: Assigned value is garbage or > undefined > length_left -= partial; >^ ~~~ > partial

[PATCH v2] usb: storage: initialize variable

2020-08-24 Thread trix
From: Tom Rix clang static analysis reports this representative problem transport.c:495:15: warning: Assigned value is garbage or undefined length_left -= partial; ^ ~~~ partial is set only when usb_stor_bulk_transfer_sglist() is successful. So set partial on