On x86 (and apparently most other Linux architectures), the union with the signal handler is the first member, but on MIPS Linux, the first struct member is sa_flags (possibly done to be compatible with IRIX). Zero out the struct and fill in the field we want by name.
This fixes a compiler warning and a test failure on Debian mips64el since 2.61.x, also seen on mipsel and mips. The function pointer is placed in the
sa_flags member, leaving
sa_handler set to
NULL, which is presumably equivalent to
SIG_DFL, and then the
SIGHUP kills the test instead of being handled.
This is a regression (bug in a new test) since 2.61.x, so no need to backport.