Author: Armin Rigo <[email protected]>
Branch:
Changeset: r3213:7eba738b73fb
Date: 2019-02-13 12:49 +0100
http://bitbucket.org/cffi/cffi/changeset/7eba738b73fb/
Log: Found out a way that appears to fix the problems on Windows
diff --git a/testing/embedding/test_thread.py b/testing/embedding/test_thread.py
--- a/testing/embedding/test_thread.py
+++ b/testing/embedding/test_thread.py
@@ -56,11 +56,6 @@
for j in range(10):
output = self._take_out(output, "adding 40 and 2 and 100\n")
output = self._take_out(output, "adding 1000, 200, 30, 4\n")
- # Windows note: fails occasionally, but it looks like a Windows
- # bug somehow. If I add fprintf(stderr, "foo\n") after the
- # final printf("done\n") in thread3-test.c, then it gets printed,
- # even though the "done\n" part is very occasionally missing
- # from the output.
assert output == ("starting\n"
"prepADD2\n"
"done\n")
diff --git a/testing/embedding/thread3-test.c b/testing/embedding/thread3-test.c
--- a/testing/embedding/thread3-test.c
+++ b/testing/embedding/thread3-test.c
@@ -51,5 +51,6 @@
assert(status == 0);
}
printf("done\n");
+ fflush(stdout); /* this is occasionally needed on Windows */
return 0;
}
_______________________________________________
pypy-commit mailing list
[email protected]
https://mail.python.org/mailman/listinfo/pypy-commit