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
path: root/t
diff options
context:
space:
mode:
authorClemens Buchacher <drizzd@aon.at>2009-05-28 00:13:43 +0400
committerJunio C Hamano <gitster@pobox.com>2009-05-28 10:16:16 +0400
commit6a01554e6350123c78de805d820e90f1c56e5fdc (patch)
tree512631158643b30cda638d18e1ca0ee70a7d3a8e /t
parente57cb0158209ece040a4b873064504efd7d2ec0e (diff)
fix segfault showing an empty remote
In case of an empty list, the search for its tail caused a NULL-pointer dereference. Signed-off-by: Clemens Buchacher <drizzd@aon.at> Reported-by: Erik Faye-Lund <kusmabite@googlemail.com> Acked-by: Jay Soffian <jaysoffian@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 't')
-rwxr-xr-xt/t5505-remote.sh10
1 files changed, 10 insertions, 0 deletions
diff --git a/t/t5505-remote.sh b/t/t5505-remote.sh
index 5ec668d6d8..e70246b3fb 100755
--- a/t/t5505-remote.sh
+++ b/t/t5505-remote.sh
@@ -494,5 +494,15 @@ test_expect_success 'remote prune to cause a dangling symref' '
grep "dangling symref" err
'
+test_expect_success 'show empty remote' '
+
+ test_create_repo empty &&
+ git clone empty empty-clone &&
+ (
+ cd empty-clone &&
+ git remote show origin
+ )
+'
+
test_done