Missing `S_ISSOCK` for stdin check
Jarred-Sumner opened this issue · comments
In Node.js & Bun, spawned subprocesses by default use socketpair
instead of pipe
for stdin. This makes it easier to prevent read() & write() calls from blocking without setting a file descriptor to O_NONBLOCK
(i.e. without observably impacting the other process which may or may not handle EAGAIN
correctly)
This usually works great, but it unfortunately seems to break using ag
in a subprocess in Bun.
Is this check missing S_ISSOCK
? or possibly isatty(0)
?
the_silver_searcher/src/options.c
Line 360 in a61f178
Related oven-sh/bun#9510
There hasn't been a single commit in 4 years. Switch from ag to something like ripgrep.