aio_cancel/7-1: fix fail occasionally due to aio_error() returns EBADF
A message that is not in the archive (sent off-list or not yet received): [email protected]
Hi!
Quoted 19 lines
Signed-off-by Peng Haitao <[email protected]>--- .../conformance/interfaces/aio_cancel/7-1.c | 6 +++--- 1 files changed, 3 insertions(+), 3 deletions(-)testcases/open_posix_testsuite/conformance/interfaces/aio_cancel/7-1.c +0
-2@@ -112,8 +112,6 @@ int main()return PTS_FAIL ; } -close (fd); - do { in_progress = 0; for (i = 0; i < BUF_NB; i++)
testcases/open_posix_testsuite/conformance/interfaces/aio_cancel/7-1.c int main() · line 164
Quoted 6 lines
testcases/open_posix_testsuite/conformance/interfaces/aio_cancel/7-1.c +2
-0@@ -161,5 +159,7 @@ int main() } }while (in_progress); +close (fd); +return PTS_UNRESOLVED ;
Yes, closing the fd before aio operation is completed is wrong. However the fix is not 100% correct either. The file would be closed only when you get out of the do while() loop, which has several returns there.
So we may rather:
* change the code to close the fd correctly
or
* don't close the fd at all as we don't care about the file anyway
Signature · 13 lines
Cyril Hrubis [email protected] ------------------------------------------------------------------------------ Special Offer -- Download ArcSight Logger for FREE! Finally, a world-class log management solution at an even better price-free! And you'll get a free "Love Thy Logs" t-shirt when you download Logger. Secure your free ArcSight Logger TODAY! http://p.sf.net/sfu/arcsisghtdev2dev _______________________________________________ Ltp-list mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/ltp-list
Hi!
Quoted 3 lines
So we may rather:
* change the code to close the fd correctly
Eg. in all codepaths
Signature · 13 lines
Cyril Hrubis [email protected] ------------------------------------------------------------------------------ Special Offer -- Download ArcSight Logger for FREE! Finally, a world-class log management solution at an even better price-free! And you'll get a free "Love Thy Logs" t-shirt when you download Logger. Secure your free ArcSight Logger TODAY! http://p.sf.net/sfu/arcsisghtdev2dev _______________________________________________ Ltp-list mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/ltp-list
A message that is not in the archive (sent off-list or not yet received): [email protected]
Hi!
Commited, thanks.
Signature · 13 lines
Cyril Hrubis [email protected] ------------------------------------------------------------------------------ All the data continuously generated in your IT infrastructure contains a definitive record of customers, application performance, security threats, fraudulent activity, and more. Splunk takes this data and makes sense of it. IT sense. And common sense. http://p.sf.net/sfu/splunk-novd2d _______________________________________________ Ltp-list mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/ltp-list