diff options
author | Junio C Hamano <gitster@pobox.com> | 2011-09-02 00:43:33 +0200 |
---|---|---|
committer | Junio C Hamano <gitster@pobox.com> | 2011-09-02 00:46:12 +0200 |
commit | 4947367267cbcd0ca528711b2393613e2e817878 (patch) | |
tree | c2a9a053ecadf7b61ef3d6017bb8ba08804342b6 /list-objects.h | |
parent | revision.c: update show_object_with_name() without using malloc() (diff) | |
download | git-4947367267cbcd0ca528711b2393613e2e817878.tar.xz git-4947367267cbcd0ca528711b2393613e2e817878.zip |
list-objects: pass callback data to show_objects()
The traverse_commit_list() API takes two callback functions, one to show
commit objects, and the other to show other kinds of objects. Even though
the former has a callback data parameter, so that the callback does not
have to rely on global state, the latter does not.
Give the show_objects() callback the same callback data parameter.
Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'list-objects.h')
-rw-r--r-- | list-objects.h | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/list-objects.h b/list-objects.h index d65dbf03e6..3db7bb6fa3 100644 --- a/list-objects.h +++ b/list-objects.h @@ -2,11 +2,10 @@ #define LIST_OBJECTS_H typedef void (*show_commit_fn)(struct commit *, void *); -typedef void (*show_object_fn)(struct object *, const struct name_path *, const char *); -typedef void (*show_edge_fn)(struct commit *); - +typedef void (*show_object_fn)(struct object *, const struct name_path *, const char *, void *); void traverse_commit_list(struct rev_info *, show_commit_fn, show_object_fn, void *); +typedef void (*show_edge_fn)(struct commit *); void mark_edges_uninteresting(struct commit_list *, struct rev_info *, show_edge_fn); #endif |