diff options
author | Junio C Hamano <gitster@pobox.com> | 2013-04-03 09:25:15 -0700 |
---|---|---|
committer | Junio C Hamano <gitster@pobox.com> | 2013-04-03 09:25:15 -0700 |
commit | a9dc3b64814f6fd1b978f10c6565bedae5965ad9 (patch) | |
tree | f4f89650414e3a772754c413e0086a68d8475d65 /archive.c | |
parent | 9e72a566995ae84862a341e3a149a4bcaf96385d (diff) | |
parent | bd54cf17a4acfb9555b8a83b7e74fb0274c38bb4 (diff) | |
download | git-a9dc3b64814f6fd1b978f10c6565bedae5965ad9.tar.gz |
Merge branch 'jk/empty-archive' into maint
"git archive" reports a failure when asked to create an archive out
of an empty tree. It would be more intuitive to give an empty
archive back in such a case.
* jk/empty-archive:
archive: handle commits with an empty tree
test-lib: factor out $GIT_UNZIP setup
Diffstat (limited to 'archive.c')
-rw-r--r-- | archive.c | 2 |
1 files changed, 1 insertions, 1 deletions
@@ -234,7 +234,7 @@ static void parse_pathspec_arg(const char **pathspec, ar_args->pathspec = pathspec = get_pathspec("", pathspec); if (pathspec) { while (*pathspec) { - if (!path_exists(ar_args->tree, *pathspec)) + if (**pathspec && !path_exists(ar_args->tree, *pathspec)) die("path not found: %s", *pathspec); pathspec++; } |