diff options
author | Karel Zak <kzak@redhat.com> | 2023-01-24 17:05:25 +0100 |
---|---|---|
committer | Karel Zak <kzak@redhat.com> | 2023-01-24 17:05:25 +0100 |
commit | 32457b5efa5d4541a7d01bed9686a4f51952cd5b (patch) | |
tree | a10bed2a0ff5b782ad868ff0f1fbb94c20d36fb0 /lib | |
parent | 46768d677fafb7535567f937b5e63b4868925f9e (diff) | |
download | util-linux-32457b5efa5d4541a7d01bed9686a4f51952cd5b.tar.gz |
include/c: add functions to print from signal handlers
Addresses: https://github.com/util-linux/util-linux/pull/2019
Signed-off-by: Karel Zak <kzak@redhat.com>
Diffstat (limited to 'lib')
-rw-r--r-- | lib/pager.c | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/lib/pager.c b/lib/pager.c index 8f62310c0..242170366 100644 --- a/lib/pager.c +++ b/lib/pager.c @@ -114,9 +114,7 @@ static int wait_or_whine(pid_t pid) if (waiting < 0) { if (errno == EINTR) continue; - /* Can't err() on signal handler */ - ignore_result(write(STDERR_FILENO, "waitpid failed", 14)); - _exit(EXIT_FAILURE); + ul_sig_err(EXIT_FAILURE, "waitpid failed"); } if (waiting != pid) return -1; |