aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJohn Keeping <john@keeping.me.uk>2015-08-12 16:41:34 +0100
committerJason A. Donenfeld <Jason@zx2c4.com>2015-08-12 17:43:08 +0200
commitda1d4c77760ff6a0eb5cbfbaf6956930089d1963 (patch)
tree58bbe2efa4e8909768ad855dad1b1f50ec793181
parent30304d8156a72ffc95e45e1aa9407319b81bd253 (diff)
ui-log: fix double counting
This crept in while rebasing the previous commit onto an updated upstream. Signed-off-by: John Keeping <john@keeping.me.uk>
Diffstat (limited to '')
-rw-r--r--ui-log.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/ui-log.c b/ui-log.c
index ff832ce..6bff948 100644
--- a/ui-log.c
+++ b/ui-log.c
@@ -476,7 +476,7 @@ void cgit_print_log(const char *tip, int ofs, int cnt, char *grep, char *pattern
if (ofs<0)
ofs = 0;
- for (i = 0; i < ofs && (commit = get_revision(&rev)) != NULL; i++) {
+ for (i = 0; i < ofs && (commit = get_revision(&rev)) != NULL; /* nop */) {
if (show_commit(commit, &rev))
i++;
free_commit_buffer(commit);
@@ -484,7 +484,7 @@ void cgit_print_log(const char *tip, int ofs, int cnt, char *grep, char *pattern
commit->parents = NULL;
}
- for (i = 0; i < cnt && (commit = get_revision(&rev)) != NULL; i++) {
+ for (i = 0; i < cnt && (commit = get_revision(&rev)) != NULL; /* nop */) {
/*
* In "follow" mode, we must count the files and lines the
* first time we invoke diff on a given commit, and we need