This is the mail archive of the
gdb-patches@sourceware.org
mailing list for the GDB project.
[PATCH OBV] [testsuite] Unbuffer the output in gdb.base/multi-forks.c
- From: Yao Qi <qiyaoltc at gmail dot com>
- To: gdb-patches at sourceware dot org
- Date: Fri, 22 Jan 2016 08:57:28 +0000
- Subject: [PATCH OBV] [testsuite] Unbuffer the output in gdb.base/multi-forks.c
- Authentication-results: sourceware.org; auth=none
This patch unbuffer the output of the program so that the test harness
can count the number of "done" from output correctly.
I'll push it in.
gdb/testsuite:
2016-01-22 Yao Qi <yao.qi@linaro.org>
PR testsuite/19491
* gdb.base/multi-forks.c: Include
../lib/unbuffer_output.c
(main): Call gdb_unbuffer_output.
---
gdb/testsuite/gdb.base/multi-forks.c | 4 ++++
1 file changed, 4 insertions(+)
diff --git a/gdb/testsuite/gdb.base/multi-forks.c b/gdb/testsuite/gdb.base/multi-forks.c
index 994d0c7..06579c8 100644
--- a/gdb/testsuite/gdb.base/multi-forks.c
+++ b/gdb/testsuite/gdb.base/multi-forks.c
@@ -20,6 +20,8 @@
#include <sys/types.h>
#include <unistd.h>
+#include "../lib/unbuffer_output.c"
+
pid_t pids[4];
int
@@ -27,6 +29,8 @@ main()
{
int i;
+ gdb_unbuffer_output ();
+
for (i = 0; i < 4; i++)
pids [i] = fork ();
--
1.9.1