summaryrefslogtreecommitdiff
path: root/builtin/fetch.c
diff options
context:
space:
mode:
authorLibravatar Junio C Hamano <gitster@pobox.com>2010-08-18 12:47:04 -0700
committerLibravatar Junio C Hamano <gitster@pobox.com>2010-08-18 12:47:04 -0700
commit6b5005c88b3a0c360249deb8ca8b92201abaa824 (patch)
tree177a02c572549b4caa5872ef3ecd4275e860b5af /builtin/fetch.c
parentMerge branch 'cc/find-commit-subject' (diff)
parentstring_list: Add STRING_LIST_INIT macro and make use of it. (diff)
downloadtgif-6b5005c88b3a0c360249deb8ca8b92201abaa824.tar.xz
Merge branch 'tf/string-list-init'
* tf/string-list-init: string_list: Add STRING_LIST_INIT macro and make use of it.
Diffstat (limited to 'builtin/fetch.c')
-rw-r--r--builtin/fetch.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/builtin/fetch.c b/builtin/fetch.c
index 680a8a97bd..ea14d5dc6b 100644
--- a/builtin/fetch.c
+++ b/builtin/fetch.c
@@ -548,8 +548,8 @@ static void find_non_local_tags(struct transport *transport,
struct ref **head,
struct ref ***tail)
{
- struct string_list existing_refs = { NULL, 0, 0, 0 };
- struct string_list remote_refs = { NULL, 0, 0, 0 };
+ struct string_list existing_refs = STRING_LIST_INIT_NODUP;
+ struct string_list remote_refs = STRING_LIST_INIT_NODUP;
const struct ref *ref;
struct string_list_item *item = NULL;
@@ -651,7 +651,7 @@ static int truncate_fetch_head(void)
static int do_fetch(struct transport *transport,
struct refspec *refs, int ref_count)
{
- struct string_list existing_refs = { NULL, 0, 0, 0 };
+ struct string_list existing_refs = STRING_LIST_INIT_NODUP;
struct string_list_item *peer_item = NULL;
struct ref *ref_map;
struct ref *rm;
@@ -875,7 +875,7 @@ static int fetch_one(struct remote *remote, int argc, const char **argv)
int cmd_fetch(int argc, const char **argv, const char *prefix)
{
int i;
- struct string_list list = { NULL, 0, 0, 0 };
+ struct string_list list = STRING_LIST_INIT_NODUP;
struct remote *remote;
int result = 0;