summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: 34779c5)
raw | patch | inline | side by side (parent: 34779c5)
author | Matthieu Moy <Matthieu.Moy@imag.fr> | |
Mon, 20 Apr 2009 11:09:37 +0000 (13:09 +0200) | ||
committer | Junio C Hamano <gitster@pobox.com> | |
Mon, 20 Apr 2009 20:53:03 +0000 (13:53 -0700) |
Commit 55f0566 (get_local_heads(): do not return random pointer if
there is no head, 2009-04-17) fixed a segfault for git push, this
patch adds a test-case to avoid future regressions.
Signed-off-by: Matthieu Moy <Matthieu.Moy@imag.fr>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
there is no head, 2009-04-17) fixed a segfault for git push, this
patch adds a test-case to avoid future regressions.
Signed-off-by: Matthieu Moy <Matthieu.Moy@imag.fr>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
t/t5701-clone-local.sh | patch | blob | history |
diff --git a/t/t5701-clone-local.sh b/t/t5701-clone-local.sh
index 3559d179647035a6ad8783aabfbecb8edcd4c254..f26b511c3ec7bf46f3fe9357cfdec9f95a169a14 100755 (executable)
--- a/t/t5701-clone-local.sh
+++ b/t/t5701-clone-local.sh
test $actual = $expected)
'
+test_expect_success 'clone empty repository, and then push should not segfault.' '
+ cd "$D" &&
+ rm -fr empty/ empty-clone/ &&
+ mkdir empty &&
+ (cd empty && git init) &&
+ git clone empty empty-clone &&
+ cd empty-clone &&
+ test_must_fail git push
+'
+
test_done