mirror of
https://github.com/Mikaela/Limnoria.git
synced 2024-11-27 05:09:23 +01:00
added support for Twisted2.0 by preventing the twisted reactor from spawning threads for dns queries.
This commit is contained in:
parent
a3e4fc5b1d
commit
26c0adf768
@ -35,10 +35,17 @@ import supybot.ircdb as ircdb
|
||||
import supybot.drivers as drivers
|
||||
import supybot.ircmsgs as ircmsgs
|
||||
|
||||
from twisted.names import client
|
||||
from twisted.internet import reactor, error
|
||||
from twisted.protocols.basic import LineReceiver
|
||||
from twisted.internet.protocol import ReconnectingClientFactory
|
||||
|
||||
|
||||
# This hack prevents the standard Twisted resolver from starting any
|
||||
# threads, which allows for a clean shut-down in Twisted>=2.0
|
||||
reactor.installResolver(client.createResolver())
|
||||
|
||||
|
||||
try:
|
||||
from OpenSSL import SSL
|
||||
from twisted.internet import ssl
|
||||
|
Loading…
Reference in New Issue
Block a user