From: Dan Carpenter Date: Wed, 8 Apr 2015 11:19:00 +0000 (+0300) Subject: staging: rtl8712: freeing an ERR_PTR X-Git-Tag: omap-for-v4.2/wakeirq-drivers~2^2~9^2~9 X-Git-Url: http://git.openpandora.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=b5eed730bd3f216dd172d2d699686000f8cb9b38;p=pandora-kernel.git staging: rtl8712: freeing an ERR_PTR If memdup_user() fails then "pparmbuf" is an error pointer and we can't pass it to kfree(). I changed the "goto _r871x_mp_ioctl_hdl_exit" to a direct return. I changed the earlier goto to a direct return as well for consistency and removed the "pparmbuf = NULL" initializer since it's no longer needed. Fixes: 45de432775d6 ('Staging: rtl8712: Use memdup_user() instead of copy_from_user()') Signed-off-by: Dan Carpenter Signed-off-by: Greg Kroah-Hartman --- Reading git-diff-tree failed