public inbox for ltp@lists.linux.it
 help / color / mirror / Atom feed
* [LTP] [PATCH] aio_cancel/3-1: call aio_read before aio_cancel
@ 2012-02-16  2:41 Kang Kai
  2012-02-16  3:25 ` Wanlong Gao
  0 siblings, 1 reply; 3+ messages in thread
From: Kang Kai @ 2012-02-16  2:41 UTC (permalink / raw)
  To: ltp-list

The case calls aio_error() with an invalid aiocbp, but it should do
some asynchronous I/O operations first, so call aio_read() and then
test the aio_error().

Signed-off-by: Kang Kai <kai.kang@windriver.com>
---
 .../conformance/interfaces/aio_error/3-1.c         |    5 ++++-
 1 files changed, 4 insertions(+), 1 deletions(-)

diff --git a/testcases/open_posix_testsuite/conformance/interfaces/aio_error/3-1.c b/testcases/open_posix_testsuite/conformance/interfaces/aio_error/3-1.c
index 8b6c2f5..6665da1 100644
--- a/testcases/open_posix_testsuite/conformance/interfaces/aio_error/3-1.c
+++ b/testcases/open_posix_testsuite/conformance/interfaces/aio_error/3-1.c
@@ -68,6 +68,9 @@ int main()
 	aiocb.aio_reqprio = -1;
 	aiocb.aio_nbytes = BUF_SIZE;
 
+	/* Just do aio_read() or aio_write */
+	aio_read(&aiocb);
+
 	ret = aio_error(&aiocb);
 
 	if (ret != EINVAL)
@@ -80,4 +83,4 @@ int main()
 	close(fd);
 	printf ("Test PASSED\n");
 	return PTS_PASS;
-}
\ No newline at end of file
+}
-- 
1.7.5.4


------------------------------------------------------------------------------
Virtualization & Cloud Management Using Capacity Planning
Cloud computing makes use of virtualization - but cloud computing 
also focuses on allowing computing to be delivered as a service.
http://www.accelacomm.com/jaw/sfnl/114/51521223/
_______________________________________________
Ltp-list mailing list
Ltp-list@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/ltp-list

^ permalink raw reply related	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2012-02-16  6:14 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2012-02-16  2:41 [LTP] [PATCH] aio_cancel/3-1: call aio_read before aio_cancel Kang Kai
2012-02-16  3:25 ` Wanlong Gao
2012-02-16  6:13   ` Kang Kai

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox