LPCManager.py
changeset 23 41616a8c80a7
parent 22 45982ef9370b
child 24 04205032298b
equal deleted inserted replaced
22:45982ef9370b 23:41616a8c80a7
  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:]