Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.kernel.org/pub/scm/git/git.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAlex Riesen <raa.lkml@gmail.com>2007-10-13 00:40:04 +0400
committerShawn O. Pearce <spearce@spearce.org>2007-10-16 04:40:50 +0400
commit8f70a7657a9b459d6a4a3bcb1628c0fa6a6c22e0 (patch)
tree32b342801a4b3ae9faf9e226bd95265b9d07d587 /remote.c
parent2467a4fa03ff849fcf2f6a93b89057aebd49c62b (diff)
Fix a crash in ls-remote when refspec expands into nothing
Originally-by: Väinö Järvelä <v@pp.inet.fi> Signed-off-by: Alex Riesen <raa.lkml@gmail.com> Signed-off-by: Lars Hjemli <hjemli@gmail.com> Signed-off-by: Shawn O. Pearce <spearce@spearce.org>
Diffstat (limited to 'remote.c')
-rw-r--r--remote.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/remote.c b/remote.c
index e2ca4d32ba..b20e2be433 100644
--- a/remote.c
+++ b/remote.c
@@ -909,7 +909,8 @@ int get_fetch_map(struct ref *remote_refs,
rm->peer_ref->name);
}
- tail_link_ref(ref_map, tail);
+ if (ref_map)
+ tail_link_ref(ref_map, tail);
return 0;
}