Skip to content

Commit

Permalink
Fix issig() to check signal_pending after dequeue SIGSTOP/SIGTSTP
Browse files Browse the repository at this point in the history
When process got SIGSTOP/SIGTSTP, issig() dequeue them and return 0.
But process could still have another signal pending after dequeue. So,
after dequeue, check and return 1, if signal_pending.

Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov>
Signed-off-by: Jitendra Patidar <jitendra.patidar@nutanix.com>
Closes openzfs#16464
  • Loading branch information
jsai20 authored and tonyhutter committed Nov 14, 2024
1 parent a6198f3 commit f6fce8e
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions module/os/linux/spl/spl-thread.c
Original file line number Diff line number Diff line change
Expand Up @@ -186,6 +186,13 @@ issig(void)

schedule();
#endif
/*
* Dequeued SIGSTOP/SIGTSTP.
* Check if process has other singal pending.
*/
if (signal_pending(current))
return (1);

return (0);
}

Expand Down

0 comments on commit f6fce8e

Please sign in to comment.