Re: [PATCH] staging: rtl: fix possible NULL pointer dereference

2017-01-11 Thread Larry Finger
On 01/11/2017 08:53 AM, Arnd Bergmann wrote: gcc-7 detects that wlanhdr_to_ethhdr() in two drivers calls memcpy() with a destination argument that an earlier function call may have set to NULL: staging/rtl8188eu/core/rtw_recv.c: In function 'wlanhdr_to_ethhdr': staging/rtl8188eu/core/rtw_recv.c:

[PATCH] staging: rtl: fix possible NULL pointer dereference

2017-01-11 Thread Arnd Bergmann
gcc-7 detects that wlanhdr_to_ethhdr() in two drivers calls memcpy() with a destination argument that an earlier function call may have set to NULL: staging/rtl8188eu/core/rtw_recv.c: In function 'wlanhdr_to_ethhdr': staging/rtl8188eu/core/rtw_recv.c:1318:2: warning: argument 1 null where non-nul