]> Cypherpunks repositories - gostls13.git/commit
internal/poll: simplify IOCP association checks
authorqmuntal <quimmuntal@gmail.com>
Thu, 5 Feb 2026 13:57:53 +0000 (14:57 +0100)
committerQuim Muntal <quimmuntal@gmail.com>
Thu, 12 Feb 2026 04:16:35 +0000 (20:16 -0800)
commitb40f0b118014f8dbc25e8ef4de82ccf78410903f
tree337802d9de4236aeab552df2b853fa1f74e7fc0b
parent54c46328ccb9d559fa21c09fd8e2dff22a99c72c
internal/poll: simplify IOCP association checks

This is a step towards deferring adding the handle to IOCP until the
first IO operation.

FD.pollable() obscures the fact that it is really checking if the handle
is associated with the IOCP. This doesn't need to be a function that
checks multiple conditions. It can be a simple boolean field that tracks
whether the handle is associated with the IOCP or not.

For #76391

Cq-Include-Trybots: luci.golang.try:gotip-windows-amd64-longtest,gotip-windows-amd64-race
Change-Id: I3ee6532f8a387fb5cfae8ae3d20ea9569f585e71
Reviewed-on: https://go-review.googlesource.com/c/go/+/742282
Reviewed-by: Michael Pratt <mpratt@google.com>
Reviewed-by: Alex Brainman <alex.brainman@gmail.com>
LUCI-TryBot-Result: Go LUCI <golang-scoped@luci-project-accounts.iam.gserviceaccount.com>
Reviewed-by: Damien Neil <dneil@google.com>
src/internal/poll/fd_windows.go