equal
deleted
inserted
replaced
1806 def __del__(self): |
1806 def __del__(self): |
1807 self.socket.close() |
1807 self.socket.close() |
1808 |
1808 |
1809 def readline(self): |
1809 def readline(self): |
1810 idx = self.Buffer.find("\n") |
1810 idx = self.Buffer.find("\n") |
1811 if idx == -1: |
1811 while idx == -1: |
1812 self.Buffer += self.socket.recv(2048) |
1812 self.Buffer += self.socket.recv(2048) |
1813 idx = self.Buffer.find("\n") |
1813 idx = self.Buffer.find("\n") |
1814 if idx != -1: |
1814 if idx != -1: |
1815 line = self.Buffer[:idx+1] |
1815 line = self.Buffer[:idx+1] |
1816 self.Buffer = self.Buffer[idx+1:] |
1816 self.Buffer = self.Buffer[idx+1:] |