git/list[1] front-page[2] threads[3] people[4] search[5] about
 

Re: [PATCH] wrapper: add workaround for open() returning EINTR

From
Taylor Blau <me@ttaylorr.com>
Date
Feb 24, 2021, 04:50 UTC
Message-ID
<YDXbDwOwNDJUZa7b@nand.local>
In-Reply-To
<YDXZY8XFRayiM1If@coredump.intra.peff.net>
On Tue, Feb 23, 2021 at 11:43:15PM -0500, Jeff King wrote:
Show 5 quoted lines
> The workaround here is enabled all the time, without a Makefile knob,
> since it's a complete noop if open() never returns EINTR. I did push it
> into its own compat/ source file, though, since it has to #undef our
> macro redirection. Putting it in a file with other code risks confusion
> if more code is added after that #undef.
Hmm. The patch below defines it in wrapper.c. Intentional?
> I do still think the OS is doing the wrong thing here. But even if I'm
> right, it's probably prudent to work around it.

Regardless of the above, I agree that if your explanation is true (and I have no reason to believe that it isn't) that the OS is indeed doing the wrong thing here.

That patch below looks quite reasonable, thanks.

Thanks, Taylor

Previous: Junio C HamanoNext: Johannes Sixt
Message 12 of 15 in “wrapper: add workaround for open() returning EINTR”
  1. wrapper: add workaround for open() returning EINTRJeff King, Feb 24, 2021
  2. Jeff KingFeb 24, 2021
  3. Junio C HamanoFeb 24, 2021
  4. Jeff KingFeb 24, 2021
  5. Makefile: add OPEN_RETURNS_EINTR knobJeff King, Feb 26, 2021
  6. Junio C HamanoFeb 26, 2021
  7. config.mak.uname: enable OPEN_RETURNS_EINTR for macOS Big SurJeff King, Mar 1, 2021
  8. Junio C HamanoMar 1, 2021
  9. Junio C HamanoMar 1, 2021
  10. Jeff KingMar 3, 2021
  11. Junio C HamanoMar 4, 2021
  12. Taylor BlauFeb 24, 2021
  13. Johannes SixtFeb 24, 2021
  14. Jeff KingFeb 24, 2021
  15. Jeff KingFeb 26, 2021

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.