From mboxrd@z Thu Jan 1 00:00:00 1970 From: Kalle Valo Subject: Re: [PATCH] mwifiex: fix potential NULL dereference and use after free Date: Thu, 13 Dec 2018 14:54:06 +0000 (UTC) Message-ID: <20181213145407.1DF896071A@smtp.codeaurora.org> References: <1543487119-92033-1-git-send-email-bianpan2016@163.com> Mime-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: 7bit Cc: Amitkumar Karwar , Nishant Sarmukadam , Ganapathi Bhat , Xinming Hu , "David S. Miller" , linux-wireless@vger.kernel.org, netdev@vger.kernel.org, linux-kernel@vger.kernel.org, Pan Bian To: Pan Bian Return-path: In-Reply-To: <1543487119-92033-1-git-send-email-bianpan2016@163.com> Sender: linux-kernel-owner@vger.kernel.org List-Id: netdev.vger.kernel.org Pan Bian wrote: > There are two defects: (1) passing a NULL bss to > mwifiex_save_hidden_ssid_channels will result in NULL dereference, > (2) using bss after dropping the reference to it via cfg80211_put_bss. > To fix them, the patch moves the buggy code to the branch that bss is > not NULL and puts it before cfg80211_put_bss. > > Signed-off-by: Pan Bian Patch applied to wireless-drivers-next.git, thanks. 1dcd9429212b mwifiex: fix potential NULL dereference and use after free -- https://patchwork.kernel.org/patch/10704311/ https://wireless.wiki.kernel.org/en/developers/documentation/submittingpatches