Re: [PATCH] drivers/net/wireless/mwl8k.c: avoid use-after-free

2013-01-06 Thread Lennert Buytenhek
On Sun, Jan 06, 2013 at 10:02:14PM -0500, Nickolai Zeldovich wrote: > > Good catch, but the patch would be better titled "mwl8k.c: avoid > > having a working driver", as the station_id return code _is_ needed > > by the caller in case of success. > > I'm not quite sure what you mean -- is there s

Re: [PATCH] drivers/net/wireless/mwl8k.c: avoid use-after-free

2013-01-06 Thread Julian Calaby
Hi Lennert, On Mon, Jan 7, 2013 at 1:48 PM, Lennert Buytenhek wrote: > On Sun, Jan 06, 2013 at 08:27:22PM -0500, Nickolai Zeldovich wrote: > >> Do not dereference p->station_id after kfree(cmd) because p >> points into the cmd data structure. > > Good catch, but the patch would be better titled "

Re: [PATCH] drivers/net/wireless/mwl8k.c: avoid use-after-free

2013-01-06 Thread Nickolai Zeldovich
On Sun, Jan 6, 2013 at 9:48 PM, Lennert Buytenhek wrote: > Good catch, but the patch would be better titled "mwl8k.c: avoid > having a working driver", as the station_id return code _is_ needed > by the caller in case of success. I'm not quite sure what you mean -- is there something subtle going

Re: [PATCH] drivers/net/wireless/mwl8k.c: avoid use-after-free

2013-01-06 Thread Lennert Buytenhek
On Sun, Jan 06, 2013 at 08:27:22PM -0500, Nickolai Zeldovich wrote: > Do not dereference p->station_id after kfree(cmd) because p > points into the cmd data structure. Good catch, but the patch would be better titled "mwl8k.c: avoid having a working driver", as the station_id return code _is_ nee

[PATCH] drivers/net/wireless/mwl8k.c: avoid use-after-free

2013-01-06 Thread Nickolai Zeldovich
Do not dereference p->station_id after kfree(cmd) because p points into the cmd data structure. Signed-off-by: Nickolai Zeldovich --- drivers/net/wireless/mwl8k.c |4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/drivers/net/wireless/mwl8k.c b/drivers/net/wireless/mwl8k.c