mirror of
				https://github.com/jlu5/PyLink.git
				synced 2025-11-04 00:47:21 +01:00 
			
		
		
		
	Irc: fix the logic checking for data in run()
This commit is contained in:
		
							parent
							
								
									e756af42ee
								
							
						
					
					
						commit
						684eac9583
					
				
							
								
								
									
										4
									
								
								main.py
									
									
									
									
									
								
							
							
						
						
									
										4
									
								
								main.py
									
									
									
									
									
								
							@ -130,8 +130,8 @@ class Irc():
 | 
			
		||||
            log.debug('(%s) self.pingtimeout: %s', self.name, self.pingtimeout)
 | 
			
		||||
            data = self.socket.recv(2048)
 | 
			
		||||
            buf += data
 | 
			
		||||
            if self.connected and not data:
 | 
			
		||||
                log.warn('(%s) No data received and self.connected is not set; disconnecting!', self.name)
 | 
			
		||||
            if self.connected.is_set() and not data:
 | 
			
		||||
                log.warn('(%s) No data received and self.connected is set; disconnecting!', self.name)
 | 
			
		||||
                break
 | 
			
		||||
            while b'\n' in buf:
 | 
			
		||||
                line, buf = buf.split(b'\n', 1)
 | 
			
		||||
 | 
			
		||||
		Loading…
	
	
			
			x
			
			
		
	
		Reference in New Issue
	
	Block a user