Date: Mon, 29 Feb 2016 19:20:24 +0000 From: bugzilla-noreply@freebsd.org To: freebsd-bugs@FreeBSD.org Subject: [Bug 203366] kevent: EV_CLEAR on fifo does not work correctly Message-ID: <bug-203366-8-RKt3WBGm7S@https.bugs.freebsd.org/bugzilla/> In-Reply-To: <bug-203366-8@https.bugs.freebsd.org/bugzilla/> References: <bug-203366-8@https.bugs.freebsd.org/bugzilla/>
index | next in thread | previous in thread | raw e-mail
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=203366 --- Comment #4 from Mark Johnston <markj@FreeBSD.org> --- Created attachment 167574 --> https://bugs.freebsd.org/bugzilla/attachment.cgi?id=167574&action=edit patch I think the patch isn't completely correct based on my interpretation of the kevent man page: if EV_EOF isn't already set, we want to activate the knote, even if EV_CLEAR is specified. That is, we should get an event if the remote side closes the FIFO. Once EV_EOF has been returned once, EV_CLEAR should clear it. To see the difference with the first patch, try trussing a tail -f <fifo> and run "(echo a; sleep 1) > <fifo>". That suggests something like the attached diff. The kevent man page also documents similar behaviour for EVFILE_WRITE, so filt_pipewrite() should be fixed as well for completeness. -- You are receiving this mail because: You are the assignee for the bug.help
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?bug-203366-8-RKt3WBGm7S>
