From 9807c972afc28abd414562fac82032f2eced3a5f Mon Sep 17 00:00:00 2001 From: "Todd C. Miller" Date: Sat, 11 Sep 2010 09:26:20 -0400 Subject: [PATCH] Quiet gcc warnings on glibc systems that use warn_unused_result for write(2). --HG-- branch : 1.7 --- exec.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/exec.c b/exec.c index 86bb7fb8f..d575a936b 100644 --- a/exec.c +++ b/exec.c @@ -524,7 +524,8 @@ handler(s) * The pipe is non-blocking, if we overflow the kernel's pipe * buffer we drop the signal. This is not a problem in practice. */ - (void)write(signal_pipe[1], &signo, sizeof(signo)); + if (write(signal_pipe[1], &signo, sizeof(signo)) == -1) + /* shut up glibc */; } /* -- 2.40.0