From 48b69a62b6abd32c5e09a2de8fdaadee9f358a04 Mon Sep 17 00:00:00 2001 From: Amit Shah Date: Wed, 7 Apr 2010 12:36:50 +0530 Subject: auto-test: nonblocking write: Report 'pass' only if everything did pass In case of the nonblock test failing, we used to report both pass and fail. Report only failure. Signed-off-by: Amit Shah --- auto-virtserial.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/auto-virtserial.c b/auto-virtserial.c index 5777583..8128dd2 100644 --- a/auto-virtserial.c +++ b/auto-virtserial.c @@ -553,7 +553,8 @@ static int test_nonblocking_write(int nr) out: ret = guest_set_port_nonblocking(nr, false); - err = result(__func__, true, "blocking", ret, 0, 0, OP_EQ, true); + if (!err) + err = result(__func__, true, "blocking", ret, 0, 0, OP_EQ, true); host_close_chardev(nr); guest_close_port(nr); return err; -- cgit