public inbox for ltp@lists.linux.it
 help / color / mirror / Atom feed
* [LTP] aio_error/3-1.c
@ 2010-10-25 20:59 Cyril Hrubis
       [not found] ` <AANLkTinUHQ6EUWi3ZhkuO0Ccd2FSSsLm6DiQpM=bZKcB@mail.gmail.com>
  0 siblings, 1 reply; 4+ messages in thread
From: Cyril Hrubis @ 2010-10-25 20:59 UTC (permalink / raw)
  To: ltp-list

Hi!
I've been reading POSIX documentation for some time now and even reading
glibc source code and the result is that aio_error/3-1.c doesn't test
anyting and should be removed.

The test is trying to assert EINVAL from aio_error accordingly to:

http://www.opengroup.org/onlinepubs/009695399/functions/aio_error.html

...

The aio_error() function may fail if:

	[EINVAL]
            The aiocbp argument does not refer to an asynchronous
	    operation whose return status has not yet been retrieved.

...


As far as I understand this, it's says you may get EINVAL if you call
aio_error() on finished aiocb second (and more) times.

This is implemented on linux as "return aiocb->__error_code" so IMHO
there is no way to test this.

-- 
Cyril Hrubis
chrubis@suse.cz

------------------------------------------------------------------------------
Nokia and AT&T present the 2010 Calling All Innovators-North America contest
Create new apps & games for the Nokia N8 for consumers in  U.S. and Canada
$10 million total in prizes - $4M cash, 500 devices, nearly $6M in marketing
Develop with Nokia Qt SDK, Web Runtime, or Java and Publish to Ovi Store 
http://p.sf.net/sfu/nokia-dev2dev
_______________________________________________
Ltp-list mailing list
Ltp-list@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/ltp-list

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

end of thread, other threads:[~2010-10-29 11:14 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2010-10-25 20:59 [LTP] aio_error/3-1.c Cyril Hrubis
     [not found] ` <AANLkTinUHQ6EUWi3ZhkuO0Ccd2FSSsLm6DiQpM=bZKcB@mail.gmail.com>
2010-10-26 16:16   ` Cyril Hrubis
     [not found]     ` <AANLkTikO=yKXhxx7giTYBMM1uerYzEj3Uj+gWY42kg3Q@mail.gmail.com>
     [not found]       ` <AANLkTi=2bCEpmjmikx4mUZFE_fBNEz-jP+jsK2He3QF-@mail.gmail.com>
2010-10-27 12:38         ` Cyril Hrubis
     [not found]           ` <AANLkTi=Fm_ZwOGFUf6+6J8GLqcPigkX=c6UzBMWnSrvi@mail.gmail.com>
2010-10-29 11:24             ` Cyril Hrubis

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