From 1fdf72444cdcf5041022c75ed616a1dcd458175b Mon Sep 17 00:00:00 2001 From: eunhhu Date: Thu, 1 Oct 2026 16:40:11 +0100 Subject: Look at a wake write's result in the prototype, as fortified builds ask Ubuntu's gcc defines _FORTIFY_SOURCE, which marks write's result as one to use, and a (void) cast does not quiet it: the prototype did not build there (research 029). Debian's does not define it; the Pi gives the same error with -D_FORTIFY_SOURCE=3. --- prototypes/connections/edit-tui.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'prototypes/connections/edit-tui.c') diff --git a/prototypes/connections/edit-tui.c b/prototypes/connections/edit-tui.c index d7b1442..2b320ee 100644 --- a/prototypes/connections/edit-tui.c +++ b/prototypes/connections/edit-tui.c @@ -55,7 +55,7 @@ static void wake_signal(int signal_number) { else stopping = 1; if (wake_write >= 0) { const char byte = 1; - (void)write((int)wake_write, &byte, 1); + if (write((int)wake_write, &byte, 1) < 0) { /* full: its reader is woken already */ } } errno = saved_errno; } -- cgit v1.2.3