[PATCH fifo 2/2] Cygwin: FIFO: add support for the duplex case

2019-03-25 Thread Ken Brown
If a FIFO is opened with O_RDWR access, create the pipe with read/write access, and make the first client have the handle of that pipe as its I/O handle. Adjust fhandler_fifo::raw_read to account for the result of trying to read from that client if there's no data. --- winsup/cygwin/fhandler.h

[PATCH fifo 0/2] Add support for duplex FIFOs

2019-03-25 Thread Ken Brown
The second patch in this series enables opening a FIFO with O_RDWR access. The underlying Windows named pipe is creted with duplex access, and its handle is made the I/O handle of the first client. While testing this, I had some mysterious crashes, which are fixed by the first patch. I tested th

[PATCH fifo 1/2] Cygwin: FIFO: avoid crashes when cloning a client

2019-03-25 Thread Ken Brown
fhandler_fifo::clone called fhandler_base::clone on each client fhandler. But those fhandlers are actually fhandler_fifo objects, so when fhandler_base::clone calls copyto, it's actually fhandler_fifo::copyto that gets called. This can lead to mysterious crashes. Fix this by simply calling clone

Re: [PATCH 0/2] default ps -W process start time to boot time when unavailable

2019-03-25 Thread Brian Inglis
On 2019-03-25 04:27, Corinna Vinschen wrote: > On Mar 23 20:22, Brian Inglis wrote: >> non-elevated users can not access system startup process start times, >> defaulting to time_t 0, displaying as Dec 31/Jan 1 depending on time zone, >> so instead use system boot time, which is within seconds of c

Re: [PATCH 0/2] default ps -W process start time to boot time when unavailable

2019-03-25 Thread Corinna Vinschen
On Mar 23 20:22, Brian Inglis wrote: > non-elevated users can not access system startup process start times, > defaulting to time_t 0, displaying as Dec 31/Jan 1 depending on time zone, > so instead use system boot time, which is within seconds of correct, > to avoid WMI overhead getting correct sy