From c68e27d50cfb255f22cf76cc9a21fe70fd0cc43e Mon Sep 17 00:00:00 2001 From: Stepan Kasal Date: Tue, 22 Apr 2014 17:43:05 +0200 Subject: [PATCH] fixup! git tag --contains : avoid stack overflow Signed-off-by: Stepan Kasal --- t/t7004-tag.sh | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/t/t7004-tag.sh b/t/t7004-tag.sh index 3f338bd5d1..86713e7637 100755 --- a/t/t7004-tag.sh +++ b/t/t7004-tag.sh @@ -1380,11 +1380,12 @@ test_expect_success 'multiple --points-at are OR-ed together' ' test_cmp expect actual ' -test_lazy_prereq BASH 'bash --version' +ulimit_stack="ulimit -s 64" +test_lazy_prereq ULIMIT 'bash -c "'"$ulimit_stack"'"' >expect # we require bash for its 'ulimit' builtin -test_expect_success BASH '--contains works in a deep repo' ' +test_expect_success ULIMIT '--contains works in a deep repo' ' i=1 && while test $i -lt 1000 do @@ -1398,7 +1399,7 @@ EOF" done | git fast-import && git checkout master && git tag far-far-away HEAD^ && - bash -c "ulimit -s 64 && git tag --contains HEAD >actual" && + bash -c "'"$ulimit_stack"' && git tag --contains HEAD >actual" && test_cmp expect actual '