error checking for tmp file