Re: [PATCH] staging: rtl8188eu: fix null dereference when kzalloc fails

2019-10-03 Thread Connor Kuehl
On 10/1/19 6:11 AM, Dan Carpenter wrote: There is another one earlier in the function as well. drivers/staging/rtl8188eu/os_dep/usb_intf.c 336 337 pnetdev = rtw_init_netdev(padapter); 338 if (!pnetdev) 339 goto free_adapter; 340 SE

Re: [PATCH] staging: rtl8188eu: fix null dereference when kzalloc fails

2019-10-01 Thread Dan Carpenter
On Fri, Sep 27, 2019 at 02:44:15PM -0700, Connor Kuehl wrote: > If kzalloc() returns NULL, the error path doesn't stop the flow of > control from entering rtw_hal_read_chip_version() which dereferences the > null pointer. Fix this by adding a 'goto' to the error path to more > gracefully handle the

[PATCH] staging: rtl8188eu: fix null dereference when kzalloc fails

2019-09-27 Thread Connor Kuehl
If kzalloc() returns NULL, the error path doesn't stop the flow of control from entering rtw_hal_read_chip_version() which dereferences the null pointer. Fix this by adding a 'goto' to the error path to more gracefully handle the issue and avoid proceeding with initialization steps that we're no lo