Use OS supplied temporary files

This commit will use temporary files that are supplied by the OS and will be automatically deleted.