mirror of
https://github.com/Mikaela/Limnoria.git
synced 2024-11-20 17:39:27 +01:00
Updated to allow all drivers to use vhosts.
This commit is contained in:
parent
1e49f9e82b
commit
ab217fc3fd
@ -71,6 +71,8 @@ class AsyncoreDriver(asynchat.async_chat, drivers.ServersMixin):
|
||||
try:
|
||||
server = self._getNextServer()
|
||||
sock = utils.getSocket(server[0])
|
||||
vhost = conf.supybot.protocols.irc.vhost()
|
||||
sock.bind((vhost, 0))
|
||||
self.set_socket(sock)
|
||||
drivers.log.connect(self.currentServer)
|
||||
self.connect(server)
|
||||
|
@ -138,6 +138,8 @@ class SocketDriver(drivers.IrcDriver, drivers.ServersMixin):
|
||||
drivers.log.connect(self.currentServer)
|
||||
try:
|
||||
self.conn = utils.getSocket(server[0])
|
||||
vhost = conf.supybot.protocols.irc.vhost()
|
||||
self.conn.bind((vhost, 0))
|
||||
except socket.error, e:
|
||||
drivers.log.connectError(self.currentServer, e)
|
||||
self.reconnect(wait=True)
|
||||
|
Loading…
Reference in New Issue
Block a user