windows: Check select error properly