Re: [staging:staging-next 133/193] drivers/staging/rtl8723au/core/rtw_mlme_ext.c:1236 OnAssocReq23a() error: we previously assumed 'p' could be null (see line 1234)

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Thu, Apr 17, 2014 at 11:50:13AM +0200, Jes Sorensen wrote:
> > Old smatch warnings:
> > drivers/staging/rtl8723au/core/rtw_mlme_ext.c:4362
> > collect_bss_info23a() error: __builtin_memcpy() 'bssid->IEs' too small
> > (768 vs u32max)
> > drivers/staging/rtl8723au/core/rtw_mlme_ext.c:4860 process_80211d()
> > error: testing array offset 'i' after use.
> 
> We already have a check in palce here - do I need to make the
> if (length > MAX_IE_SZ) check for length < 0 to make this warning go
> away?

Oh.  Wait.  I responded to the wrong thing.

Yeah.  You could check for negatives or make length unsigned or you
could check skb->len to make sure it wasn't too short.  Any of those
would work.

regards,
dan carpenter

_______________________________________________
devel mailing list
devel@xxxxxxxxxxxxxxxxxxxxxx
http://driverdev.linuxdriverproject.org/mailman/listinfo/driverdev-devel




[Index of Archives]     [Linux Driver Backports]     [DMA Engine]     [Linux GPIO]     [Linux SPI]     [Video for Linux]     [Linux USB Devel]     [Linux Coverity]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [Yosemite Backpacking]
  Powered by Linux