OpenSSLSocket is currently using the zero byte read trick on Windows to poll for read readiness when peaking at the data to determine whether the incoming connection is performing an SSL handshake. However, io::read is designed to provide consistent semantics for a zero byte read across posix and windows, which is to return immediately.
To fix this, we can either:
(1) Have different semantics for zero byte io::read on posix / windows, where we just let it fall through to the system calls. This might be confusing for users, but it's unlikely that a caller would perform a zero byte read in typical code so the confusion is probably avoided.
(2) Implement io::poll for reads on windows. This would make the caller code consistent and is probably less confusing to users.