From a1e442e06f3119466d5d0daaca3b16aa00825bb9 Mon Sep 17 00:00:00 2001 From: Alex Crichton Date: Sat, 23 Dec 2017 19:45:37 -0800 Subject: [PATCH] Write invalid data when cloning to force an abort Otherwise it seems libgit2 isn't ready to handle premature eof? Unclear... --- tests/git.rs | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/tests/git.rs b/tests/git.rs index 33ffe8c16..ce2836a78 100644 --- a/tests/git.rs +++ b/tests/git.rs @@ -2205,7 +2205,9 @@ fn failed_submodule_checkout() { let t = thread::spawn(move || { while !done2.load(Ordering::SeqCst) { - drop(listener.accept()); + if let Ok((mut socket, _)) = listener.accept() { + drop(socket.write_all(b"foo\r\n")); + } } }); -- 2.30.2