]> Cypherpunks repositories - gostls13.git/commit
[release-branch.go1.9] internal/poll: do not call SetFileCompletionNotificationModes...
authorAlex Brainman <alex.brainman@gmail.com>
Wed, 11 Oct 2017 07:15:25 +0000 (18:15 +1100)
committerRuss Cox <rsc@golang.org>
Wed, 25 Oct 2017 20:23:29 +0000 (20:23 +0000)
commitf259aed0822dd42182b297740e3c5dcd09e40a84
tree7d916089e8593ec0fbbcc02532f8ac28bf89b696
parent39d4bb9c0f3ac3f87de64b069ea176595e39d46c
[release-branch.go1.9] internal/poll: do not call SetFileCompletionNotificationModes if it is broken

Current code assumes that SetFileCompletionNotificationModes
is safe to call even if we know that it is not safe to use
FILE_SKIP_COMPLETION_PORT_ON_SUCCESS flag. It appears (see issue #22149),
SetFileCompletionNotificationModes crashes when we call it without
FILE_SKIP_COMPLETION_PORT_ON_SUCCESS flag.

Do not call SetFileCompletionNotificationModes in that situation.
We are allowed to do that, because SetFileCompletionNotificationModes
is just an optimisation.

Fixes #22149

Change-Id: I0ad3aff4eabd8c27739417a62c286b1819ae166a
Reviewed-on: https://go-review.googlesource.com/69870
Reviewed-by: Ian Lance Taylor <iant@golang.org>
Reviewed-on: https://go-review.googlesource.com/70989
Run-TryBot: Russ Cox <rsc@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Alex Brainman <alex.brainman@gmail.com>
src/internal/poll/fd_windows.go