User: Password:
|
|
Subscribe / Log in / New account

Kernel events without kevents

Kernel events without kevents

Posted Mar 15, 2007 11:05 UTC (Thu) by pphaneuf (subscriber, #23480)
In reply to: Kernel events without kevents by Ross
Parent article: Kernel events without kevents

Netscape 4.x was a single-threaded, event-driven program, so you do like every other file descriptor, set it non-blocking, and ignore EAGAIN.

Was that a trick question, because if so, I don't get it.


(Log in to post comments)

Kernel events without kevents

Posted Mar 15, 2007 12:43 UTC (Thu) by nix (subscriber, #2304) [Link]

Netscape 4 had a habit of going into interminable stalls :)

Kernel events without kevents

Posted Mar 15, 2007 12:50 UTC (Thu) by pphaneuf (subscriber, #23480) [Link]

Ah, there are many ways in which to wedge one-self, but thankfully, I think the simplest ones were indeed avoided. ;-)

The way Netscape 4 would wedge itself the most often for me (because I would often strace it when it did, since I was working on a big event-driven single-threaded program as well, and I'm curious to boot!) was to be reading the same file descriptor over and over, getting zero, and not getting the hint, for some reason.

I suspect there was a bit of code that wanted to do just the ONE synchronous thing, and of course, it screwed up and blocked the whole program. Tsk tsk tsk...


Copyright © 2017, Eklektix, Inc.
Comments and public postings are copyrighted by their creators.
Linux is a registered trademark of Linus Torvalds