redoing get_temp_file_dir