summaryrefslogtreecommitdiff
path: root/src/iterator.h
diff options
context:
space:
mode:
authorEdward Thomson <ethomson@github.com>2016-03-21 16:51:45 -0400
committerEdward Thomson <ethomson@github.com>2016-03-24 15:59:48 -0400
commit247e3b4305f317bede88a225788239df57a8aa6d (patch)
tree767b0c9639a2299be4c650a8fdf7e51e3acae462 /src/iterator.h
parent0ef0b71ca5ce45a064dafe66462c7e9c143678ac (diff)
downloadlibgit2-247e3b4305f317bede88a225788239df57a8aa6d.tar.gz
iterator: mandate `advance_over`
Since the three iterators implement `advance_over` differently, mandate it and implement each.
Diffstat (limited to 'src/iterator.h')
-rw-r--r--src/iterator.h6
1 files changed, 1 insertions, 5 deletions
diff --git a/src/iterator.h b/src/iterator.h
index 460f9475a..51ba3f777 100644
--- a/src/iterator.h
+++ b/src/iterator.h
@@ -217,11 +217,7 @@ GIT_INLINE(int) git_iterator_advance_over(
git_iterator_status_t *status,
git_iterator *iter)
{
- if (iter->cb->advance_over)
- return iter->cb->advance_over(entry, status, iter);
-
- *status = GIT_ITERATOR_STATUS_NORMAL;
- return git_iterator_advance(entry, iter);
+ return iter->cb->advance_over(entry, status, iter);
}
/**