Skip to content
This repository was archived by the owner on Nov 9, 2017. It is now read-only.

Commit c68e27d

Browse files
committed
fixup! git tag --contains : avoid stack overflow
Signed-off-by: Stepan Kasal <[email protected]>
1 parent c63d196 commit c68e27d

File tree

1 file changed

+4
-3
lines changed

1 file changed

+4
-3
lines changed

t/t7004-tag.sh

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1380,11 +1380,12 @@ test_expect_success 'multiple --points-at are OR-ed together' '
13801380
test_cmp expect actual
13811381
'
13821382
1383-
test_lazy_prereq BASH 'bash --version'
1383+
ulimit_stack="ulimit -s 64"
1384+
test_lazy_prereq ULIMIT 'bash -c "'"$ulimit_stack"'"'
13841385
13851386
>expect
13861387
# we require bash for its 'ulimit' builtin
1387-
test_expect_success BASH '--contains works in a deep repo' '
1388+
test_expect_success ULIMIT '--contains works in a deep repo' '
13881389
i=1 &&
13891390
while test $i -lt 1000
13901391
do
@@ -1398,7 +1399,7 @@ EOF"
13981399
done | git fast-import &&
13991400
git checkout master &&
14001401
git tag far-far-away HEAD^ &&
1401-
bash -c "ulimit -s 64 && git tag --contains HEAD >actual" &&
1402+
bash -c "'"$ulimit_stack"' && git tag --contains HEAD >actual" &&
14021403
test_cmp expect actual
14031404
'
14041405

0 commit comments

Comments
 (0)