Used self.socket in NetworkThread