tools/udpTools/udpClientEtherInfo.c
/*
 * Prints the packet payload, given an Ethernet type code for the payload's
 * protocol.
 *
 * Returns non-zero if it can do so, zero if the ethertype is unknown.
 */
Prints the packet payload, given an Ethernet type code for the payload's
protocol.

Returns non-zero if it can do so, zero if the ethertype is unknown.
Prints the packet payload given an Ethernet type code for the payload ' s protocol . Returns non - zero if it can do so zero if the ethertype is unknown .
int etherTypeHandle(netdissect_options *ndo, u_short ether_type, const u_char *p,
      u_int length, u_int caplen, const struct lladdr_info *src, const struct lladdr_info *dst) {
  switch (ether_type) {
  case ETHERTYPE_IP:
    ipHandle(ndo, p, length);
    return (1);
  default:
    return (0);
  }
}
int etherTypeHandle ( netdissect_options * ndo , u_short ether_type , const u_char * p , u_int length , u_int caplen , const struct lladdr_info * src , const struct lladdr_info * dst ) { switch ( ether_type ) { case ETHERTYPE_IP : ipHandle ( ndo , p , length ) ; return ( 1 ) ; default : return ( 0 ) ; } }
Prints the packet payload, given an Ethernet type code for the payload's
 protocol.
Prints the packet payload given an Ethernet type code for the payload ' s protocol .