• Bryan C. Mills's avatar
    runtime/cgo: return correct sa_flags · 4210930a
    Bryan C. Mills authored
    A typo in the previous revision ("act" instead of "oldact") caused us
    to return the sa_flags from the new (or zeroed) sigaction rather than
    the old one.
    
    In the presence of a signal handler registered before
    runtime.libpreinit, this caused setsigstack to erroneously zero out
    important sa_flags (such as SA_SIGINFO) in its attempt to re-register
    the existing handler with SA_ONSTACK.
    
    Change-Id: I3cd5152a38ec0d44ae611f183bc1651d65b8a115
    Reviewed-on: https://go-review.googlesource.com/37852
    Run-TryBot: Bryan Mills <bcmills@google.com>
    TryBot-Result: Gobot Gobot <gobot@golang.org>
    Reviewed-by: 's avatarIan Lance Taylor <iant@golang.org>
    4210930a
gcc_sigaction.c 1.9 KB