mirror of
				https://github.com/ergochat/ergo.git
				synced 2025-10-31 22:07:23 +01:00 
			
		
		
		
	
		
			
				
	
	
		
			15 lines
		
	
	
		
			308 B
		
	
	
	
		
			Go
		
	
	
	
	
	
			
		
		
	
	
			15 lines
		
	
	
		
			308 B
		
	
	
	
		
			Go
		
	
	
	
	
	
| // +build !linux
 | |
| 
 | |
| package utils
 | |
| 
 | |
| import (
 | |
| 	"fmt"
 | |
| 	"net"
 | |
| )
 | |
| 
 | |
| // Output a description of a connection that can identify it to other systems
 | |
| // administration tools.
 | |
| func DescribeConn(conn net.Conn) (description string) {
 | |
| 	return fmt.Sprintf("%s <-> %s", conn.LocalAddr().String(), conn.RemoteAddr().String())
 | |
| }
 | 
