Commit 161737a6 authored by Kirill Tkhai's avatar Kirill Tkhai Committed by Greg Kroah-Hartman

staging: slicoss: Fix possible reuse of freed memory in timer function

Do not call kfree() till timer function is finished.

[This was found using grep. Compiled tested only]
Signed-off-by: default avatarKirill Tkhai <tkhai@yandex.ru>
CC: Joe Perches <joe@perches.com>
CC: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent aa6d5e4c
......@@ -2970,7 +2970,7 @@ static void slic_card_cleanup(struct sliccard *card)
{
if (card->loadtimerset) {
card->loadtimerset = 0;
del_timer(&card->loadtimer);
del_timer_sync(&card->loadtimer);
}
slic_debug_card_destroy(card);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment