hi

I need to know the names and members of structs that represent TCP and UDP headers in linux.As far as I know,the following are names of header structures:
-struct ip
-struct udphdr
-struct icmp

I googled to see what members struct udphdr has and :
struct udphdr {
u_short uh_sport; /* src port */
u_short uh_dport; /* dst port */
short uh_ulen; /* udp length */
u_short uh_sum; /* checksum */
};

But for some reason cc reports that struct udphdr doesn't contain any of those members.So what are the names of members in linux?


Are there any alternatives to these structures(maybe struct iphdr or struct udp)?

thank you