slydiman wrote:

I have reverted the original `PipeWindows::CreateNew()` removed in this 
[commit](https://github.com/llvm/llvm-project/commit/e55850be23a09969a3a619c4767d86cd532b1006).
 Note the following comment was here at the beginning and it is correct. See 
also [here for more 
details](https://stackoverflow.com/questions/60645/overlapped-i-o-on-anonymous-pipe).

> Even for anonymous pipes, we open a named pipe. This is because you cannot 
> get overlapped i/o on Windows without using a named pipe.  So we synthesize a 
> unique name.

We cannot use ::CreatePipe() because this pipe does not support async I/O. 

Note the inheritance did not work for name pipes on Windows because of missing 
or incorrectly initialized SECURITY_ATTRIBUTES.

Note ReadWithTimeout() never worked as expected because of `timeout = 
duration.count() * 1000;` instead of `timeout = duration.count() / 1000;`. 

I have also fixed the logic of error checking.


https://github.com/llvm/llvm-project/pull/101383
_______________________________________________
lldb-commits mailing list
lldb-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits

Reply via email to