/[lwip]/lwip/src/core/ipv4/ip.c
ViewVC logotype

Diff of /lwip/src/core/ipv4/ip.c

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1.26.2.5 by jani, Tue Oct 28 11:51:35 2003 UTC revision 1.26.2.6 by jani, Tue Nov 4 11:47:51 2003 UTC
# Line 235  ip_input(struct pbuf *p, struct netif *i Line 235  ip_input(struct pbuf *p, struct netif *i
235    iphdr = p->payload;    iphdr = p->payload;
236    if (IPH_V(iphdr) != 4) {    if (IPH_V(iphdr) != 4) {
237      LWIP_DEBUGF(IP_DEBUG | 1, ("IP packet dropped due to bad version number %u\n", IPH_V(iphdr)));      LWIP_DEBUGF(IP_DEBUG | 1, ("IP packet dropped due to bad version number %u\n", IPH_V(iphdr)));
 #if IP_DEBUG  
238      ip_debug_print(p);      ip_debug_print(p);
 #endif /* IP_DEBUG */  
239      pbuf_free(p);      pbuf_free(p);
240      IP_STATS_INC(ip.err);      IP_STATS_INC(ip.err);
241      IP_STATS_INC(ip.drop);      IP_STATS_INC(ip.drop);
# Line 265  ip_input(struct pbuf *p, struct netif *i Line 263  ip_input(struct pbuf *p, struct netif *i
263    if (inet_chksum(iphdr, iphdrlen) != 0) {    if (inet_chksum(iphdr, iphdrlen) != 0) {
264    
265      LWIP_DEBUGF(IP_DEBUG | 2, ("Checksum (0x%x) failed, IP packet dropped.\n", inet_chksum(iphdr, iphdrlen)));      LWIP_DEBUGF(IP_DEBUG | 2, ("Checksum (0x%x) failed, IP packet dropped.\n", inet_chksum(iphdr, iphdrlen)));
 #if IP_DEBUG  
266      ip_debug_print(p);      ip_debug_print(p);
 #endif /* IP_DEBUG */  
267      pbuf_free(p);      pbuf_free(p);
268      IP_STATS_INC(ip.chkerr);      IP_STATS_INC(ip.chkerr);
269      IP_STATS_INC(ip.drop);      IP_STATS_INC(ip.drop);
# Line 374  ip_input(struct pbuf *p, struct netif *i Line 370  ip_input(struct pbuf *p, struct netif *i
370  #endif /* IP_OPTIONS == 0 */  #endif /* IP_OPTIONS == 0 */
371    
372    /* send to upper layers */    /* send to upper layers */
 #if IP_DEBUG  
373    LWIP_DEBUGF(IP_DEBUG, ("ip_input: \n"));    LWIP_DEBUGF(IP_DEBUG, ("ip_input: \n"));
374    ip_debug_print(p);    ip_debug_print(p);
375    LWIP_DEBUGF(IP_DEBUG, ("ip_input: p->len %d p->tot_len %d\n", p->len, p->tot_len));    LWIP_DEBUGF(IP_DEBUG, ("ip_input: p->len %d p->tot_len %d\n", p->len, p->tot_len));
 #endif /* IP_DEBUG */  
376    
377  #if LWIP_RAW  #if LWIP_RAW
378    if (!raw_input(p, inp)) {    if (!raw_input(p, inp)) {
# Line 487  ip_output_if(struct pbuf *p, struct ip_a Line 481  ip_output_if(struct pbuf *p, struct ip_a
481    IP_STATS_INC(ip.xmit);    IP_STATS_INC(ip.xmit);
482    
483    LWIP_DEBUGF(IP_DEBUG, ("ip_output_if: %c%c%u\n", netif->name[0], netif->name[1], netif->num));    LWIP_DEBUGF(IP_DEBUG, ("ip_output_if: %c%c%u\n", netif->name[0], netif->name[1], netif->num));
 #if IP_DEBUG  
484    ip_debug_print(p);    ip_debug_print(p);
 #endif /* IP_DEBUG */  
485    
486    LWIP_DEBUGF(IP_DEBUG, ("netif->output()"));    LWIP_DEBUGF(IP_DEBUG, ("netif->output()"));
487    

Legend:
Removed from v.1.26.2.5  
changed lines
  Added in v.1.26.2.6

savannah-hackers-public@gnu.org
ViewVC Help
Powered by ViewVC 1.1.26