lkml.org 
[lkml]   [2022]   [Sep]   [27]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH V3] mISDN: fix use-after-free bugs in l1oip timer handlers
On Sat, 24 Sep 2022 10:18:42 +0800 Duoming Zhou wrote:
> + del_timer_sync(&hc->keep_tl);
> + del_timer_sync(&hc->timeout_tl);
> + cancel_work_sync(&hc->workq);
> + del_timer_sync(&hc->keep_tl);
> cancel_work_sync(&hc->workq);

Why not add a bit which will indicate that the device is shutting
down and check it in places which schedule the timer?
I think that's much easier to reason about and we won't need to do
this rep cancel procedure.

\
 
 \ /
  Last update: 2022-09-28 02:27    [W:0.043 / U:0.264 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site