summaryrefslogtreecommitdiff
path: root/builtin
diff options
context:
space:
mode:
authorMichael Haggerty <mhagger@alum.mit.edu>2015-07-28 21:08:21 (GMT)
committerJunio C Hamano <gitster@pobox.com>2015-07-28 21:39:26 (GMT)
commitbc598c32ae41cd355169ca7b207c2e35d9449232 (patch)
treec7481cbe8f796da33ae53582a12bae419a125c51 /builtin
parent5f65499fa281748421f2ae65cd794533ada4b4de (diff)
downloadgit-bc598c32ae41cd355169ca7b207c2e35d9449232.zip
git-bc598c32ae41cd355169ca7b207c2e35d9449232.tar.gz
git-bc598c32ae41cd355169ca7b207c2e35d9449232.tar.bz2
get_remote_group(): use skip_prefix()
Signed-off-by: Michael Haggerty <mhagger@alum.mit.edu> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'builtin')
-rw-r--r--builtin/fetch.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/builtin/fetch.c b/builtin/fetch.c
index bbc2bb8..262809c 100644
--- a/builtin/fetch.c
+++ b/builtin/fetch.c
@@ -973,8 +973,7 @@ static int get_remote_group(const char *key, const char *value, void *priv)
{
struct remote_group_data *g = priv;
- if (starts_with(key, "remotes.") &&
- !strcmp(key + 8, g->name)) {
+ if (skip_prefix(key, "remotes.", &key) && !strcmp(key, g->name)) {
/* split list by white space */
while (*value) {
size_t wordlen = strcspn(value, " \t\n");