summaryrefslogtreecommitdiff
path: root/examples/network/fetch.c
diff options
context:
space:
mode:
authorVicent Martí <vicent@github.com>2012-12-05 11:47:19 -0800
committerVicent Martí <vicent@github.com>2012-12-05 11:47:19 -0800
commite05ca13f1f3550f59790c0f992841abceee1b4c5 (patch)
treea01c119011d0c6020c9288096d09ed055c475bd8 /examples/network/fetch.c
parenta541eafa606b58e7ce3df8e496da8e032fdb74ec (diff)
parentee1c33b146a366260a4648b1f29f470fedaca0fa (diff)
downloadlibgit2-e05ca13f1f3550f59790c0f992841abceee1b4c5.tar.gz
Merge pull request #1115 from ben/struct-versions
Version info for public structs
Diffstat (limited to 'examples/network/fetch.c')
-rw-r--r--examples/network/fetch.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/examples/network/fetch.c b/examples/network/fetch.c
index e341d2d6c..8048fd67a 100644
--- a/examples/network/fetch.c
+++ b/examples/network/fetch.c
@@ -70,7 +70,7 @@ int fetch(git_repository *repo, int argc, char **argv)
const git_transfer_progress *stats;
pthread_t worker;
struct dl_data data;
- git_remote_callbacks callbacks;
+ git_remote_callbacks callbacks = GIT_REMOTE_CALLBACKS_INIT;
argc = argc;
// Figure out whether it's a named remote or a URL
@@ -81,7 +81,6 @@ int fetch(git_repository *repo, int argc, char **argv)
}
// Set up the callbacks (only update_tips for now)
- memset(&callbacks, 0, sizeof(callbacks));
callbacks.update_tips = &update_cb;
callbacks.progress = &progress_cb;
git_remote_set_callbacks(remote, &callbacks);