Re: [PATCH] mac80211: fix incorrect error return path on tmp allocation failure

2016-10-28 Thread Johannes Berg
On Fri, 2016-10-28 at 19:08 +0100, Colin King wrote: > From: Colin Ian King > > The current exit path when tmp fails to be allocated is via the > fail label which frees tfm2 which has not yet been allocated, > which is problematic since tfm2 is not initialized and is a

Re: [PATCH] mac80211: fix incorrect error return path on tmp allocation failure

2016-10-28 Thread Johannes Berg
On Fri, 2016-10-28 at 19:08 +0100, Colin King wrote: > From: Colin Ian King > > The current exit path when tmp fails to be allocated is via the > fail label which frees tfm2 which has not yet been allocated, > which is problematic since tfm2 is not initialized and is a garbage > pointer. Fix

[PATCH] mac80211: fix incorrect error return path on tmp allocation failure

2016-10-28 Thread Colin King
From: Colin Ian King The current exit path when tmp fails to be allocated is via the fail label which frees tfm2 which has not yet been allocated, which is problematic since tfm2 is not initialized and is a garbage pointer. Fix this by exiting directly to the return at

[PATCH] mac80211: fix incorrect error return path on tmp allocation failure

2016-10-28 Thread Colin King
From: Colin Ian King The current exit path when tmp fails to be allocated is via the fail label which frees tfm2 which has not yet been allocated, which is problematic since tfm2 is not initialized and is a garbage pointer. Fix this by exiting directly to the return at the end of the function