Don't set error twice (oops)

This commit is contained in:
Colomban Wendling 2012-02-05 19:46:59 +01:00
parent 0a22e8a624
commit e686681385

View File

@ -1222,6 +1222,7 @@ static gboolean build_create_shellscript(const gchar *fname, const gchar *cmd, g
if (fclose(fp) != 0) if (fclose(fp) != 0)
{ {
if (error && ! *error) /* don't set error twice */
set_file_error_from_errno(error, errno, "Failed to close file"); set_file_error_from_errno(error, errno, "Failed to close file");
success = FALSE; success = FALSE;
} }