Merge pull request #486 from devjoa/fix-temp-file-on-windows

Fix Windows 10 temp file handling