public inbox for glibc-bugs@sourceware.org help / color / mirror / Atom feed
From: "carlos at redhat dot com" <sourceware-bugzilla@sourceware.org> To: glibc-bugs@sourceware.org Subject: [Bug stdio/29459] New: fwrite does not return EPIPE when underlying write fails with EPIPE. Date: Mon, 08 Aug 2022 17:32:57 +0000 [thread overview] Message-ID: <bug-29459-131@http.sourceware.org/bugzilla/> (raw) https://sourceware.org/bugzilla/show_bug.cgi?id=29459 Bug ID: 29459 Summary: fwrite does not return EPIPE when underlying write fails with EPIPE. Product: glibc Version: 2.36 Status: NEW Severity: normal Priority: P2 Component: stdio Assignee: unassigned at sourceware dot org Reporter: carlos at redhat dot com Target Milestone: --- This was reported downstream for CentOS 9 Stream here: https://bugzilla.redhat.com/show_bug.cgi?id=2112672 The issue is an upstream issue that needs review. The test case is attached from the downstream issue. An strace shows the issue clearly: 1659979752.806415 write(1, "hello\n", 6) = 6 1659979752.806467 write(2, "1. fwrite wrote 6 bytes and ferror is 0\n", 40) = 40 1659979752.806517 write(1, "hello\n", 6) = -1 EPIPE (Broken pipe) 1659979752.806548 --- SIGPIPE {si_signo=SIGPIPE, si_code=SI_USER, si_pid=202616, si_uid=1000} --- 1659979752.806563 write(2, "2. fwrite wrote 6 bytes and ferror is 1\n", 40) = 40 The underlying write fails with EPIPE, but fwrite doesn't itself fail. -- You are receiving this mail because: You are on the CC list for the bug.
next reply other threads:[~2022-08-08 17:32 UTC|newest] Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top 2022-08-08 17:32 carlos at redhat dot com [this message] 2022-08-08 17:33 ` [Bug stdio/29459] " carlos at redhat dot com 2022-08-08 17:33 ` carlos at redhat dot com 2022-08-08 17:35 ` carlos at redhat dot com 2022-08-08 17:50 ` schwab@linux-m68k.org 2022-08-08 19:19 ` carlos at redhat dot com 2022-08-08 19:57 ` sam at gentoo dot org
Reply instructions: You may reply publicly to this message via plain-text email using any one of the following methods: * Save the following mbox file, import it into your mail client, and reply-to-all from there: mbox Avoid top-posting and favor interleaved quoting: https://en.wikipedia.org/wiki/Posting_style#Interleaved_style * Reply using the --to, --cc, and --in-reply-to switches of git-send-email(1): git send-email \ --in-reply-to=bug-29459-131@http.sourceware.org/bugzilla/ \ --to=sourceware-bugzilla@sourceware.org \ --cc=glibc-bugs@sourceware.org \ /path/to/YOUR_REPLY https://kernel.org/pub/software/scm/git/docs/git-send-email.html * If your mail client supports setting the In-Reply-To header via mailto: links, try the mailto: linkBe sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox; as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).