mirror of
https://github.com/jlu5/PyLink.git
synced 2024-11-01 01:09:22 +01:00
classes: track hopcount in Server
This commit is contained in:
parent
76a0eb78e3
commit
663bfe462c
@ -1630,6 +1630,13 @@ class Server():
|
|||||||
self.desc = desc
|
self.desc = desc
|
||||||
self._irc = irc
|
self._irc = irc
|
||||||
|
|
||||||
|
assert uplink is None or uplink in self._irc.servers, "Unknown uplink %s" % uplink
|
||||||
|
|
||||||
|
if uplink is None:
|
||||||
|
self.hopcount = 1
|
||||||
|
else:
|
||||||
|
self.hopcount = self._irc.servers[uplink].hopcount + 1
|
||||||
|
|
||||||
# Has the server finished bursting yet?
|
# Has the server finished bursting yet?
|
||||||
self.has_eob = False
|
self.has_eob = False
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user