archive-tar: report filter start error only once
A missing tar filter is reported by start_command() using error(), but also by its caller, write_tar_filter_archive(), using die(): $ git -c tar.invalid.command=foo archive --format=invalid HEAD error: cannot run foo: No such file or directory fatal: unable to start 'foo' filter: No such file or directory The second message contains all relevant information and even says that the failed command was intended to be used as a filter. Silence the first one because it's redundant. Signed-off-by: René Scharfe <l.s.r@web.de> Signed-off-by: Taylor Blau <me@ttaylorr.com>
This commit is contained in:
committed by
Taylor Blau
parent
63bba4fdd8
commit
1e4ea950f7
@ -498,6 +498,7 @@ static int write_tar_filter_archive(const struct archiver *ar,
|
||||
strvec_push(&filter.args, cmd.buf);
|
||||
filter.use_shell = 1;
|
||||
filter.in = -1;
|
||||
filter.silent_exec_failure = 1;
|
||||
|
||||
if (start_command(&filter) < 0)
|
||||
die_errno(_("unable to start '%s' filter"), cmd.buf);
|
||||
|
||||
Reference in New Issue
Block a user