mirror of
https://github.com/Mikaela/Limnoria.git
synced 2024-11-29 22:29:24 +01:00
0f1011081e
When a driver's run() method crashes, supybot.drivers.run() marks it as dead and sets its 'irc' attribute to None. This would be fine for "normal" independent drivers (like Socket used to be), because this driver would never be called again. But now that we use select(), some other thread may hold a reference to this driver in a select() call frame, and call the dead driver's '_read()' method when there is data to be read from the socket. There is already a safeguard in '_read()' in the case the socket could be read from, but this safeguard was missing from _handleSocketError. This caused the "live" driver's select() to crash, which propagagated to its run(), which caused the driver to be marked as dead, etc. Eventually, all drivers could die, and we end up with the dreadful "Schedule is the only remaining driver, why do we continue to live?" in an infinite loop. |
||
---|---|---|
.. | ||
drivers | ||
utils | ||
__init__.py | ||
ansi.py | ||
callbacks.py | ||
cdb.py | ||
commands.py | ||
conf.py | ||
dbi.py | ||
dynamicScope.py | ||
gpg.py | ||
httpserver.py | ||
i18n.py | ||
ircdb.py | ||
irclib.py | ||
ircmsgs.py | ||
ircutils.py | ||
log.py | ||
plugin.py | ||
plugins | ||
questions.py | ||
registry.py | ||
schedule.py | ||
setup.py | ||
shlex.py | ||
test.py | ||
unpreserve.py | ||
world.py |