From ee52f46d74e027f6fa04f29d35726b8af9734baa Mon Sep 17 00:00:00 2001 From: Heiko Voigt Date: Wed, 16 Jun 2010 20:11:00 +0200 Subject: [PATCH] work around misdetection of stdin attached to a tty Git on Windows was made aware of the fact that sometimes a file may be used by another process and so an operation may fail but the user might be able to fix it and is asking for confirmation whether it should retry. This is implemented in a way that git only asks in case stdin and stderr are attached to a tty. Unfortunately this seems to be misdetected sometimes causing the testsuite to hang when git is waiting for a user answer. This patch works around the situation. Signed-off-by: Heiko Voigt --- t/test-lib.sh | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/t/test-lib.sh b/t/test-lib.sh index e28d5fdebe..102762188a 100644 --- a/t/test-lib.sh +++ b/t/test-lib.sh @@ -15,6 +15,10 @@ # You should have received a copy of the GNU General Public License # along with this program. If not, see http://www.gnu.org/licenses/ . +# for git on windows so stdin will not be misdetected as attached to a +# terminal +exec < /dev/null + # if --tee was passed, write the output not only to the terminal, but # additionally to the file test-results/$BASENAME.out, too. case "$GIT_TEST_TEE_STARTED, $* " in -- 2.11.4.GIT