Apply read and write deadlines to pending IO

In order to upgrade to go1.8 all IO operations
including previous pending IO must have the deadline
set when SetReadDeadline or SetWriteDeadline is called

Signed-off-by: Darren Stahl <darst@microsoft.com>
This commit is contained in:
Darren Stahl
2017-05-05 14:53:42 -07:00
parent 2a0317319a
commit 899dbf3ba5
2 changed files with 107 additions and 46 deletions
+1 -1
View File
@@ -367,7 +367,7 @@ func connectPipe(p *win32File) error {
return err
}
err = connectNamedPipe(p.handle, &c.o)
_, err = p.asyncIo(c, time.Time{}, 0, err)
_, err = p.asyncIo(c, nil, 0, err)
if err != nil && err != cERROR_PIPE_CONNECTED {
return err
}