diff options
author | Amit Shah <amit.shah@redhat.com> | 2010-04-07 12:36:50 +0530 |
---|---|---|
committer | Amit Shah <amit.shah@redhat.com> | 2010-04-07 12:36:50 +0530 |
commit | 48b69a62b6abd32c5e09a2de8fdaadee9f358a04 (patch) | |
tree | a39e13f772359545d6d7bbaaaf8cfd80a3bdf484 | |
parent | 9407f48fbb923391a6172d6fffd409b40411ec13 (diff) | |
download | test-virtserial-48b69a62b6abd32c5e09a2de8fdaadee9f358a04.tar.gz test-virtserial-48b69a62b6abd32c5e09a2de8fdaadee9f358a04.tar.xz test-virtserial-48b69a62b6abd32c5e09a2de8fdaadee9f358a04.zip |
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 <amit.shah@redhat.com>
-rw-r--r-- | auto-virtserial.c | 3 |
1 files changed, 2 insertions, 1 deletions
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; |