[LTP] [PATCH v6 2/3] Add a library wrapper for sigaction()

Cyril Hrubis chrubis@suse.cz
Tue Mar 13 13:27:29 CET 2018


Hi!
> +static inline int safe_sigaction(const char *file, const int lineno,
> +				 int signum, const struct sigaction *act,
> +				 struct sigaction *oldact)
> +{
> +	int rval;
> +
> +	rval = sigaction(signum, act, oldact);
> +
> +	if (rval == -1) {
> +		tst_brk_(file, lineno, TBROK | TERRNO,
> +			"sigaction(%d, %p, %p) failed", signum, act, oldact);
                                   ^
				   I've added tst_strsig() here as well
				   to get better error messages.

And I had to move the function the C source to avoid tst_strsig()
redefinition warnings...

And pushed, thanks.

-- 
Cyril Hrubis
chrubis@suse.cz


More information about the ltp mailing list