git/log: fix log count
saved wrong version when rebasing, oops.
This commit is contained in:
parent
126cc163e2
commit
c2c397422f
1 changed files with 3 additions and 3 deletions
|
@ -14,7 +14,7 @@ Biobuf *out;
|
||||||
char *queryexpr;
|
char *queryexpr;
|
||||||
char *commitid;
|
char *commitid;
|
||||||
int shortlog;
|
int shortlog;
|
||||||
int msgcount;
|
int msgcount = -1;
|
||||||
|
|
||||||
Objset done;
|
Objset done;
|
||||||
Objq objq;
|
Objq objq;
|
||||||
|
@ -181,7 +181,7 @@ showquery(char *q)
|
||||||
|
|
||||||
if((n = resolverefs(&h, q)) == -1)
|
if((n = resolverefs(&h, q)) == -1)
|
||||||
sysfatal("resolve: %r");
|
sysfatal("resolve: %r");
|
||||||
for(i = 0; i < n && msgcount-- > 0; i++){
|
for(i = 0; i < n && (msgcount == -1 || msgcount-- > 0); i++){
|
||||||
if((o = readobject(h[i])) == nil)
|
if((o = readobject(h[i])) == nil)
|
||||||
sysfatal("read %H: %r", h[i]);
|
sysfatal("read %H: %r", h[i]);
|
||||||
show(o);
|
show(o);
|
||||||
|
@ -207,7 +207,7 @@ showcommits(char *c)
|
||||||
qinit(&objq);
|
qinit(&objq);
|
||||||
osinit(&done);
|
osinit(&done);
|
||||||
qput(&objq, o, 0);
|
qput(&objq, o, 0);
|
||||||
while(qpop(&objq, &e) && msgcount-- > 0){
|
while(qpop(&objq, &e) && (msgcount == -1 || msgcount-- > 0)){
|
||||||
show(e.o);
|
show(e.o);
|
||||||
for(i = 0; i < e.o->commit->nparent; i++){
|
for(i = 0; i < e.o->commit->nparent; i++){
|
||||||
if(oshas(&done, e.o->commit->parent[i]))
|
if(oshas(&done, e.o->commit->parent[i]))
|
||||||
|
|
Loading…
Reference in a new issue