Merge pull request #10700 from sepalani/ssl-handshake Socket: Fix some non-blocking connect edge cases