[libgit2-glib] Fix walk example
- From: Ignacio Casal Quinteiro <icq src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [libgit2-glib] Fix walk example
- Date: Tue, 4 Dec 2012 12:52:42 +0000 (UTC)
commit 1970545068777db4021168b3b66918d65190bb8b
Author: Ignacio Casal Quinteiro <icq gnome org>
Date: Tue Dec 4 13:51:44 2012 +0100
Fix walk example
examples/walk.c | 7 ++++---
1 files changed, 4 insertions(+), 3 deletions(-)
---
diff --git a/examples/walk.c b/examples/walk.c
index 499a948..392de4f 100644
--- a/examples/walk.c
+++ b/examples/walk.c
@@ -115,7 +115,7 @@ main (int argc,
head = ggit_repository_get_head (repo, &err);
g_assert_no_error (err);
- oid = ggit_ref_get_id (head);
+ oid = ggit_ref_get_target (head);
ggit_revision_walker_push (revwalker, oid, &err);
g_assert_no_error (err);
@@ -170,9 +170,10 @@ main (int argc,
commit_tree = ggit_commit_get_tree (commit);
parent_tree = ggit_commit_get_tree (parent_commit);
- diff = ggit_diff_new_tree_to_tree (repo, NULL,
+ diff = ggit_diff_new_tree_to_tree (repo,
parent_tree,
- commit_tree, &err);
+ commit_tree,
+ NULL, &err);
g_assert_no_error (err);
ggit_diff_print_patch (diff, diff_print_cb, NULL, &err);
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]