Added chmod to temp file.