Skip to content

staging: rtl8188eu: fix Coverity defects in os_dep/ioctl_linux.c

Christian Engelmayer lkml 1 version In review

Get series with b4
b4 am 20140428225431.2ea55d58@spike

Versions newest first

  1. v1 Latest5 patches 1 replyIn review

Patches in v1 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/5staging: rtl8188eu: fix potential leak in rtw_wx_read32()drivers/staging/rtl8188eu/os_dep/ioctl_linux.c+9 -61 reply
2/5staging: rtl8188eu: fix potential leak in rtw_wx_set_enc_ext()drivers/staging/rtl8188eu/os_dep/ioctl_linux.c+3 -10 replies
3/5staging: rtl8188eu: fix potential leak in rtw_mp_QueryDrv()drivers/staging/rtl8188eu/os_dep/ioctl_linux.c+8 -30 replies
4/5staging: rtl8188eu: fix potential leak in rtw_mp_SetRFPath()drivers/staging/rtl8188eu/os_dep/ioctl_linux.c+8 -30 replies
5/5staging: rtl8188eu: fix potential leak in rtw_mp_pwrtrk()drivers/staging/rtl8188eu/os_dep/ioctl_linux.c+17 -110 replies

Reviews trailers per patch

1 of 5 patches has a Reviewed-by or Acked-by.

PatchLarry Finger
1/5A-b
2/5
3/5
4/5
5/5

Trailers given in replies are filled; those carried in the patches from earlier versions are outlined with dashes.

Read the v1 thread

Cover letter [PATCH 0/5] staging: rtl8188eu: fix Coverity defects in os_dep/ioctl_linux.c

This is a cleanup of staging/rtl8188eu/os_dep/ioctl_linux.c regarding Coverity resource leak findings.

The changes leave the current implementation intact and just attack the problems in the error paths, however, it seems that we could get easily rid of some of the mallocs altogether.

   char *input = kmalloc(wrqu->data.length, GFP_KERNEL);
   copy_from_user(input, wrqu->data.pointer, wrqu->data.length);
   qAutoLoad = strncmp(input, "autoload", 8);

The series is compile tested and applies against branch staging-next of tree git.kernel.org/pub/scm/linux/kernel/git/gregkh/staging.git

Christian Engelmayer (5):
staging: rtl8188eu: fix potential leak in rtw_wx_read32()
staging: rtl8188eu: fix potential leak in rtw_wx_set_enc_ext()
staging: rtl8188eu: fix potential leak in rtw_mp_QueryDrv()
staging: rtl8188eu: fix potential leak in rtw_mp_SetRFPath()
staging: rtl8188eu: fix potential leak in rtw_mp_pwrtrk()

 drivers/staging/rtl8188eu/os_dep/ioctl_linux.c | 69 +++++++++++++++++---------
 1 file changed, 45 insertions(+), 24 deletions(-)
Signature · 1 line
1.9.1