mirror of
				https://github.com/yggdrasil-network/yggdrasil-go.git
				synced 2025-11-04 03:05:07 +03:00 
			
		
		
		
	comment out pointless error that prints on some platforms and not others
This commit is contained in:
		
							parent
							
								
									5f1ddbb038
								
							
						
					
					
						commit
						2e95a3131c
					
				
					 1 changed files with 3 additions and 2 deletions
				
			
		| 
						 | 
				
			
			@ -31,7 +31,7 @@ func (w *tunWriter) _write(b []byte) {
 | 
			
		|||
	if n == 0 {
 | 
			
		||||
		return
 | 
			
		||||
	}
 | 
			
		||||
	written, err = w.tun.iface.Write(append(make([]byte, TUN_OFFSET_BYTES), b[:n]...), TUN_OFFSET_BYTES)
 | 
			
		||||
	written, err = w.tun.iface.Write(append(make([]byte, TUN_OFFSET_BYTES), b...), TUN_OFFSET_BYTES)
 | 
			
		||||
	util.PutBytes(b)
 | 
			
		||||
	if err != nil {
 | 
			
		||||
		w.tun.Act(w, func() {
 | 
			
		||||
| 
						 | 
				
			
			@ -41,7 +41,8 @@ func (w *tunWriter) _write(b []byte) {
 | 
			
		|||
		})
 | 
			
		||||
	}
 | 
			
		||||
	if written != n+TUN_OFFSET_BYTES {
 | 
			
		||||
		w.tun.log.Errorln("TUN iface write mismatch:", written, "bytes written vs", n, "bytes given")
 | 
			
		||||
		// FIXME some platforms return the wrong number of bytes written, causing error spam
 | 
			
		||||
		//w.tun.log.Errorln("TUN iface write mismatch:", written, "bytes written vs", n+TUN_OFFSET_BYTES, "bytes given")
 | 
			
		||||
	}
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue