mirror of
https://git.proxmox.com/git/libgit2
synced 2025-07-09 06:23:16 +00:00
more examples/log.c bug fixing
This commit is contained in:
parent
5a169711fa
commit
733c4f3aca
@ -94,11 +94,11 @@ static int add_revision(struct log_state *s, const char *revstr)
|
||||
if (*revstr == '^') {
|
||||
revs.flags = GIT_REVPARSE_SINGLE;
|
||||
hide = !hide;
|
||||
if (!git_revparse_single(&revs.from, s->repo, revstr + 1))
|
||||
return -1;
|
||||
} else
|
||||
if (!git_revparse(&revs, s->repo, revstr))
|
||||
|
||||
if (git_revparse_single(&revs.from, s->repo, revstr + 1) < 0)
|
||||
return -1;
|
||||
} else if (git_revparse(&revs, s->repo, revstr) < 0)
|
||||
return -1;
|
||||
|
||||
if ((revs.flags & GIT_REVPARSE_SINGLE) != 0)
|
||||
push_rev(s, revs.from, hide);
|
||||
|
Loading…
Reference in New Issue
Block a user