summaryrefslogtreecommitdiff
path: root/t
diff options
context:
space:
mode:
authorLibravatar Junio C Hamano <gitster@pobox.com>2017-07-31 13:51:05 -0700
committerLibravatar Junio C Hamano <gitster@pobox.com>2017-07-31 13:51:06 -0700
commit42dbdef1cac298c3faaab389b67a41005022fdfa (patch)
tree8ffc0063c316b8ae8ba4d8aefc32428533d435de /t
parentMerge branch 'pw/unquote-path-in-git-pm' into maint (diff)
parentt: handle EOF in test_copy_bytes() (diff)
downloadtgif-42dbdef1cac298c3faaab389b67a41005022fdfa.tar.xz
Merge branch 'jk/test-copy-bytes-fix' into maint
A test fix. * jk/test-copy-bytes-fix: t: handle EOF in test_copy_bytes()
Diffstat (limited to 't')
-rw-r--r--t/test-lib-functions.sh1
1 files changed, 1 insertions, 0 deletions
diff --git a/t/test-lib-functions.sh b/t/test-lib-functions.sh
index db622c3555..50a9a1d1c4 100644
--- a/t/test-lib-functions.sh
+++ b/t/test-lib-functions.sh
@@ -999,6 +999,7 @@ test_copy_bytes () {
my $s;
my $nread = sysread(STDIN, $s, $len);
die "cannot read: $!" unless defined($nread);
+ last unless $nread;
print $s;
$len -= $nread;
}