David Miller <davem@xxxxxxxxxxxxx> writes: > if (!prefixcmp(key, "branch.")) { > name = key + 7; > subkey = strrchr(name, '.'); > branch = make_branch(name, subkey - name); > > What if 'subkey' is NULL? I bet that's what happening here. Wow, good eyes. It makes me wonder what my C library has been returning during the tests... --- remote.c | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-) diff --git a/remote.c b/remote.c index 3fb0f99..0e00680 100644 --- a/remote.c +++ b/remote.c @@ -220,11 +220,11 @@ static int handle_config(const char *key, const char *value) if (!prefixcmp(key, "branch.")) { name = key + 7; subkey = strrchr(name, '.'); - branch = make_branch(name, subkey - name); if (!subkey) return 0; if (!value) return 0; + branch = make_branch(name, subkey - name); if (!strcmp(subkey, ".remote")) { branch->remote_name = xstrdup(value); if (branch == current_branch) - To unsubscribe from this list: send the line "unsubscribe git" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html