Fix invalid open() flag on non-Windows machines

O_BINARY seems to be Windows specific.