drivers: wifi: Clean up exit path
Fix couple of bugs in exit path:
- In case of calloc failure, return's without unlocking
- memory is freed outside lock, in case of a tiny window of race, this
can cause a crash when this function is called from two threads.
Signed-off-by:
Chaitanya Tata <Chaitanya.Tata@nordicsemi.no>
Loading
Please sign in to comment