test cancel_pending to save a thr_wake call in some specical cases.
This commit is contained in:
parent
56073c9eac
commit
b774466b61
@ -61,7 +61,7 @@ sigcancel_handler(int sig __unused,
|
||||
{
|
||||
struct pthread *curthread = _get_curthread();
|
||||
|
||||
if (curthread->cancel_defer)
|
||||
if (curthread->cancel_defer && curthread->cancel_pending)
|
||||
thr_wake(curthread->tid);
|
||||
_thr_ast(curthread);
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user