summaryrefslogtreecommitdiffstats
path: root/src/build.h
diff options
context:
space:
mode:
authorKevin Adler <kadler@us.ibm.com>2020-10-31 05:35:44 (GMT)
committerKevin Adler <kadler@us.ibm.com>2020-10-31 06:02:37 (GMT)
commit7ea6c537d2968effb024634a6367a1a1b4cafeb4 (patch)
treed4215b7068389d83e05f074775ca293e07d734a5 /src/build.h
parentd45ff8ebf88ef4add46a80ccdfc2d97a8b4b091b (diff)
downloadNinja-7ea6c537d2968effb024634a6367a1a1b4cafeb4.zip
Ninja-7ea6c537d2968effb024634a6367a1a1b4cafeb4.tar.gz
Ninja-7ea6c537d2968effb024634a6367a1a1b4cafeb4.tar.bz2
Handle process signalling correctly on AIX
POSIX shells set the exit code to 128 + the signal number, which coincidentally matches the layout used by the WIFSIGNALLED/WTERMSIG macros on most Unix-like systems, but not on AIX. Instead, AIX stores the signal value in the bottom 8 bits and also bits 16-23. The only time ninja currently handles signals correctly is when the shell used to call the program dies via signal. To handle both scenarios, we detect the shell exit code format and convert it to the format that the WIFSIGNALED/WTERMSIG macros expect. Fixes #1623
Diffstat (limited to 'src/build.h')
0 files changed, 0 insertions, 0 deletions