https://bugs.winehq.org/show_bug.cgi?id=54413
--- Comment #5 from Zeb Figura z.figura12@gmail.com --- (In reply to Zeb Figura from comment #4)
Safer is probably just to pass WSAGetOverlappedResult() a garbage handle value, one that would in practice never be allocated.
Actually we already do that. This test exists because it does, I think, have value—we want to show that it's not enough for the handle to be valid, it has to be a handle that ws2_32 knows about. I don't think there's another way to prove that, we need to use DuplicateHandle().
So instead I sent a patch that reorders the two tests, and puts the more "destructive" iocp_async_read_closesocket() at the end.
Hopefully that's enough to make this failure go away...