Hi Vincent,

I assumed that for Windows you could already distinguish between pipes and normal files since the pty check uses the pipe name as part of its check. If not...

The fstat() st_mode field has S_IFIFO which indicates a first-in first-out (pipe) file.

Some of the documentation I saw said that S_IFIFO is for named pipes, I don't know what it will return for stdin being a pipe.

fstat() takes a file descriptor, so you'll need to convert a HANDLE to a fd.

If you can get Windows working I'm happy to take care of the Unix side.

Cheers,
Alistair


You are receiving this because you commented.
Reply to this email directly, view it on GitHub, or mute the thread.