getTempFile(): Added error return if no temp files available"