Date: Fri, 30 Jun 2017 21:53:05 +0000 From: bugzilla-noreply@freebsd.org To: freebsd-bugs@FreeBSD.org Subject: [Bug 220398] lio_listio(2) never sends asynchronous notification if nent==0 Message-ID: <bug-220398-8@https.bugs.freebsd.org/bugzilla/>
next in thread | raw e-mail | index | archive | help
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=220398 Bug ID: 220398 Summary: lio_listio(2) never sends asynchronous notification if nent==0 Product: Base System Version: CURRENT Hardware: Any OS: Any Status: New Severity: Affects Some People Priority: --- Component: kern Assignee: freebsd-bugs@FreeBSD.org Reporter: asomers@FreeBSD.org Created attachment 183968 --> https://bugs.freebsd.org/bugzilla/attachment.cgi?id=183968&action=edit Reproduction program It may seem stupid, but you can call lio_listio(2) with an empty aiocb list. I would naively expect lio_listio to do nothing and return in that case. Indeed, that's what it does when mode == LIO_WAIT. However, if mode == LIO_NOWAIT, then asynchronous notifications never get delivered. With SIGEV_KEVENT, no kevent is ever delivered, and with SIGEV_SIGNAL, no signal is ever delivered. I haven't checked other SIGEV_ values. The attached program demonstrates the problem: it calls lio_listio with LIO_NOWAIT and notification via SIGTERM. But no signal ever gets delivered, so the program exits normally. jhb feels that the Open Group's specification is ambiguous on this point, but that sending asynchronous notification immediately would be sensible. -- You are receiving this mail because: You are the assignee for the bug.
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?bug-220398-8>
