diff -urN traceproto-1.1.1.orig/tp_packet.c traceproto-1.1.1/tp_packet.c --- traceproto-1.1.1.orig/tp_packet.c 2005-01-31 01:03:57.248742848 -0500 +++ traceproto-1.1.1/tp_packet.c 2005-01-31 01:06:39.184124928 -0500 @@ -103,7 +103,7 @@ state.low_ttl = YES; // tcp_hdr = ( struct libnet_tcp_hdr * ) & raw_packet[ 0 ]; - tcp_hdr = ( struct libnet_tcp_hdr * ) tp_align ( raw_packet, + tcp_hdr = ( struct libnet_tcp_hdr * ) tp_align ( (char *)raw_packet, 0, sizeof ( struct libnet_tcp_hdr ) ); @@ -165,7 +165,7 @@ state.low_ttl = YES; // udp_hdr = ( struct libnet_udp_hdr * ) & raw_packet[ 0 ]; - udp_hdr = ( struct libnet_udp_hdr * ) tp_align ( raw_packet, + udp_hdr = ( struct libnet_udp_hdr * ) tp_align ( (char *)raw_packet, 0, sizeof ( struct libnet_udp_hdr ) ); @@ -268,12 +268,12 @@ * off of the packet */ // eth_hdr = ( struct libnet_802_3_hdr * ) raw_packet; - eth_hdr = ( struct libnet_802_3_hdr * ) tp_align ( raw_packet, + eth_hdr = ( struct libnet_802_3_hdr * ) tp_align ( (char *)raw_packet, 0, sizeof ( struct libnet_802_3_hdr ) ); // state.ip_hdr = ( struct libnet_ipv4_hdr * ) & raw_packet[ eth_offset ]; - state.ip_hdr = ( struct libnet_ipv4_hdr * ) tp_align ( raw_packet, + state.ip_hdr = ( struct libnet_ipv4_hdr * ) tp_align ( (char *)raw_packet, eth_offset, sizeof ( struct libnet_ipv4_hdr ) ); @@ -294,19 +294,19 @@ { case IPPROTO_ICMP: // return parse_icmp_packet ( ( const u_char * ) & raw_packet [ ipv4_offset ] ); - return parse_icmp_packet ( ( const u_char * ) tp_align ( raw_packet, + return parse_icmp_packet ( ( const u_char * ) tp_align ( (char *)raw_packet, ipv4_offset, sizeof ( struct libnet_icmpv4_hdr ) ) ); break; case IPPROTO_TCP: // return parse_tcp_packet ( ( const u_char * ) & raw_packet [ ipv4_offset ] ); - return parse_tcp_packet ( ( const u_char * ) tp_align ( raw_packet, + return parse_tcp_packet ( ( const u_char * ) tp_align ( (char *)raw_packet, ipv4_offset, sizeof ( struct libnet_tcp_hdr ) ) ); break; case IPPROTO_UDP: // return parse_udp_packet ( ( const u_char * ) & raw_packet [ ipv4_offset ] ); - return parse_udp_packet ( ( const u_char * ) tp_align ( raw_packet, + return parse_udp_packet ( ( const u_char * ) tp_align ( (char *)raw_packet, ipv4_offset, sizeof ( struct libnet_udp_hdr ) ) ); break;