HomeFreeBSD

Simplify signal handling code in libthr by removing use of SYS_sigreturn

Description

Simplify signal handling code in libthr by removing use of SYS_sigreturn

The use of SYS_sigreturn is unnecessary here.

If handle_signal is called when a signal is delivered, it can just
return normally back to sigcode which will call sigreturn anyway.

In case handle_signal is called by check_deferred_signal, using
setcontext is better than SYS_sigreturn because that is the correct
system call to pair with the earlier getcontext.

Reviewed by: imp, kib
Differential Revision: https://reviews.freebsd.org/D44893

Details

Provenance
dg612_cam.ac.ukAuthored on Jun 3 2024, 6:18 PM
impCommitted on Jun 6 2024, 9:48 PM
Reviewer
imp
Differential Revision
D44893: Simplify signal handling code in libthr by removing use of SYS_sigreturn
Parents
rGc0c066f86dd1: config: Remove redundant code
Branches
Unknown
Tags
Unknown