problemas com a libnet

afpr

Membro

boas..

Estou usando a versao 1.1.2.1-5 da libnet e ao compilar um programa obtenho os seguintes erros:


libnet-example-1.c:160: warning: passing argument 8 of ‘libnet_build_tcp’ makes integer from pointer without a cast
libnet-example-1.c:160: error: too few arguments to function ‘libnet_build_tcp’
libnet-example-1.c:166: warning: passing argument 1 of ‘libnet_do_checksum’ from incompatible pointer type
libnet-example-1.c:166: warning: passing argument 2 of ‘libnet_do_checksum’ makes pointer from integer without a cast
libnet-example-1.c:166: error: too few arguments to function ‘libnet_do_checksum’

o codigo das referidas funçoes é:

libnet_build_tcp(src_prt, /* source TCP port */
dst_prt, /* destination TCP port */
0xa1d95, /* sequence number */
0x53, /* acknowledgement number */
TH_SYN, /* control flags */
1024, /* window size */
0, /* urgent pointer */
NULL, /* payload (none) */
0, /* payload length */
packet + LIBNET_IP_H); /* packet header memory */


libnet_do_checksum(packet, IPPROTO_TCP, LIBNET_TCP_H)

Alguem me pode ajudar?

obrigado
 
Back
Topo