Skip to content

Commit 7094175

Browse files
max630gitster
authored andcommitted
t5562: do not depend on /dev/zero
It was reported [1] that NonStop platform does not have /dev/zero. The test uses /dev/zero as a dummy input. Passing case (http-backed failed because of too big input size) should not be reading anything from it. If http-backend would erroneously try to read any data returning EOF probably would be even safer than providing some meaningless data. Replace /dev/zero with /dev/null to avoid issues with platforms which do not have /dev/zero. [1] https://public-inbox.org/git/[email protected]/ Reported-by: Randall S. Becker <[email protected]> Signed-off-by: Max Kirillov <[email protected]> Signed-off-by: Junio C Hamano <[email protected]>
1 parent d991948 commit 7094175

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

t/t5562-http-backend-content-length.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -150,7 +150,7 @@ test_expect_success 'CONTENT_LENGTH overflow ssite_t' '
150150
GIT_HTTP_EXPORT_ALL=TRUE \
151151
REQUEST_METHOD=POST \
152152
CONTENT_LENGTH="$NOT_FIT_IN_SSIZE" \
153-
git http-backend </dev/zero >/dev/null 2>err &&
153+
git http-backend </dev/null >/dev/null 2>err &&
154154
grep "fatal:.*CONTENT_LENGTH" err
155155
'
156156

0 commit comments

Comments
 (0)