Skip to content

Conversation

@tpetazzoni
Copy link

src/check_run.c defines sig_handler() under the following conditions:

#if defined(HAVE_FORK) && HAVE_FORK==1

however, it does use sig_handler under the following conditions:

#if defined(HAVE_SIGACTION) && defined(HAVE_FORK)

which breaks when HAVE_FORK is defined, but has the value HAVE_FORK=0, as is the case on noMMU platforms.

This commit fixes this by ensuring that the build conditions are aligned throughout check_run.c.

Fixes:

src/check_run.c: In function 'srunner_run_tagged': src/check_run.c:802:38: error: 'sig_handler' undeclared (first use in this function); did you mean 'sa_handler'? [...]

src/check_run.c defines sig_handler() under the following conditions:

  #if defined(HAVE_FORK) && HAVE_FORK==1

however, it does use sig_handler under the following conditions:

  #if defined(HAVE_SIGACTION) && defined(HAVE_FORK)

which breaks when HAVE_FORK is defined, but has the value HAVE_FORK=0,
as is the case on noMMU platforms.

This commit fixes this by ensuring that the build conditions are
aligned throughout check_run.c.

Fixes:

src/check_run.c: In function 'srunner_run_tagged':
src/check_run.c:802:38: error: 'sig_handler' undeclared (first use in this function); did you mean 'sa_handler'?
[...]

Signed-off-by: Thomas Petazzoni <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant