diff options
author | Junio C Hamano <gitster@pobox.com> | 2010-08-18 12:47:04 -0700 |
---|---|---|
committer | Junio C Hamano <gitster@pobox.com> | 2010-08-18 12:47:04 -0700 |
commit | 6b5005c88b3a0c360249deb8ca8b92201abaa824 (patch) | |
tree | 177a02c572549b4caa5872ef3ecd4275e860b5af /builtin/remote.c | |
parent | 165dc789d5e201a06e0de5a984e4529ae62027fc (diff) | |
parent | 183113a5ca99cb228b2ba0a29e53f1ac11f2c7c2 (diff) | |
download | git-6b5005c88b3a0c360249deb8ca8b92201abaa824.tar.gz |
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/remote.c')
-rw-r--r-- | builtin/remote.c | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/builtin/remote.c b/builtin/remote.c index 6699bc5712..48e0a6bf26 100644 --- a/builtin/remote.c +++ b/builtin/remote.c @@ -134,7 +134,7 @@ static int add_branch(const char *key, const char *branchname, static int add(int argc, const char **argv) { int fetch = 0, mirror = 0, fetch_tags = TAGS_DEFAULT; - struct string_list track = { NULL, 0, 0 }; + struct string_list track = STRING_LIST_INIT_NODUP; const char *master = NULL; struct remote *remote; struct strbuf buf = STRBUF_INIT, buf2 = STRBUF_INIT; @@ -596,7 +596,7 @@ static int mv(int argc, const char **argv) }; struct remote *oldremote, *newremote; struct strbuf buf = STRBUF_INIT, buf2 = STRBUF_INIT, buf3 = STRBUF_INIT; - struct string_list remote_branches = { NULL, 0, 0, 0 }; + struct string_list remote_branches = STRING_LIST_INIT_NODUP; struct rename_info rename; int i; @@ -734,8 +734,8 @@ static int rm(int argc, const char **argv) struct remote *remote; struct strbuf buf = STRBUF_INIT; struct known_remotes known_remotes = { NULL, NULL }; - struct string_list branches = { NULL, 0, 0, 1 }; - struct string_list skipped = { NULL, 0, 0, 1 }; + struct string_list branches = STRING_LIST_INIT_DUP; + struct string_list skipped = STRING_LIST_INIT_DUP; struct branches_for_remote cb_data; int i, result; @@ -1044,7 +1044,7 @@ static int show(int argc, const char **argv) OPT_END() }; struct ref_states states; - struct string_list info_list = { NULL, 0, 0, 0 }; + struct string_list info_list = STRING_LIST_INIT_NODUP; struct show_info info; argc = parse_options(argc, argv, NULL, options, builtin_remote_show_usage, @@ -1483,7 +1483,7 @@ static int get_one_entry(struct remote *remote, void *priv) static int show_all(void) { - struct string_list list = { NULL, 0, 0 }; + struct string_list list = STRING_LIST_INIT_NODUP; int result; list.strdup_strings = 1; |