Py3k fixes for Windows