From 019f63596cdb62af7959f24d6c542a8d57081113 Mon Sep 17 00:00:00 2001 From: Joel Rosdahl Date: Thu, 11 Dec 2003 18:39:40 +0000 Subject: Don't send PING in the registration phase, just disconnect --- miniircd | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/miniircd b/miniircd index ddffcb9..1858ba0 100755 --- a/miniircd +++ b/miniircd @@ -129,8 +129,13 @@ class Client(object): self.disconnect("ping timeout") return if not self.__sentPing and self.timestamp + 90 < now: - self.message("PING :%s" % self.__server.name) - self.__sentPing = True + if self.__handleCommand == self.__commandHandler: + # Registered. + self.message("PING :%s" % self.__server.name) + self.__sentPing = True + else: + # Not registered. + self.disconnect("ping timeout") def writeQueueSize(self): return len(self.__writebuffer) -- cgit v1.2.3