rtl8188eu: On kernel 2.6.32, a NULL dereference was found

This bug was reported and debugged by GitHub user jdowells.

Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net>
This commit is contained in:
Larry Finger 2015-05-15 15:20:51 -05:00
parent d76cbb313d
commit b5cf1b0cf3

View file

@ -9571,6 +9571,8 @@ static int rtw_ioctl_wext_private(struct net_device *dev, union iwreq_data *wrq_
memcpy(&wdata, wrq_data, sizeof(wdata));
input_len = wdata.data.length;
if (input_len == 0)
return -EFAULT;
input = rtw_zmalloc(input_len);
if (NULL == input)
return -ENOMEM;