plan 9 kernel history: overview | file list | diff list

2001/0623/ip/ip.c (diff list | history)

2001/0430/sys/src/9/ip/ip.c:344,3502001/0623/sys/src/9/ip/ip.c:344,350 (short | long | prev | next)
1998/0313    
#define DBG(x)	if((logmask & Logipmsg) && (iponly == 0 || x == iponly))netlog 
1997/0327    
 
void 
1998/0313    
ipiput(Fs *f, uchar *ia, Block *bp) 
2001/0623    
ipiput(Fs *f, Ipifc *ifc, Block *bp) 
1997/0327    
{ 
1998/0313    
	int hl; 
1997/0327    
	Iphdr *h; 
2001/0430/sys/src/9/ip/ip.c:428,4342001/0623/sys/src/9/ip/ip.c:428,434
1998/1209    
		/* don't forward if packet has timed out */ 
		if(h->ttl <= 1){ 
2000/0706    
			ip->stats[InHdrErrors]++; 
1998/1209    
			icmpttlexceeded(f, ia, bp); 
2001/0623    
			icmpttlexceeded(f, ifc, bp); 
1998/1209    
			freeblist(bp); 
			return; 
		} 
2001/0430/sys/src/9/ip/ip.c:455,4612001/0623/sys/src/9/ip/ip.c:455,461
1998/0313    
	p = Fsrcvpcol(f, h->proto); 
	if(p != nil && p->rcv != nil) { 
2000/0706    
		ip->stats[InDelivers]++; 
1998/0313    
		(*p->rcv)(p, ia, bp); 
2001/0623    
		(*p->rcv)(p, ifc, bp); 
1998/0313    
		return; 
	} 
2000/0706    
	ip->stats[InDiscards]++; 


source code copyright © 1990-2005 Lucent Technologies; see license
Plan 9 distribution
comments to russ cox (rsc@swtch.com)