--- embedaddon/libnet/sample/icmp6_echoreq.c 2013/07/22 11:54:41 1.1.1.2 +++ embedaddon/libnet/sample/icmp6_echoreq.c 2023/09/27 11:11:38 1.1.1.3 @@ -1,5 +1,5 @@ /* - * $Id: icmp6_echoreq.c,v 1.1.1.2 2013/07/22 11:54:41 misho Exp $ + * $Id: icmp6_echoreq.c,v 1.1.1.3 2023/09/27 11:11:38 misho Exp $ * * Poseidon++ (c) 1996 - 2002 Mike D. Schiffman * Redone from synflood example by Stefan Schlott @@ -85,7 +85,7 @@ main(int argc, char **argv) } *cp++ = 0; dst_prt = (u_short)atoi(cp); - dst_ip = libnet_name2addr6(l, optarg, 1); + dst_ip = libnet_name2addr6(l, optarg, LIBNET_RESOLVE); if (strncmp((char*)&dst_ip,(char*)&in6addr_error,sizeof(in6addr_error))==0) { fprintf(stderr, "Bad IP6 address: %s\n", optarg); @@ -126,7 +126,7 @@ main(int argc, char **argv) char payload[56]; int i; for (i=0; i<56; i++) payload[i]='A'+((char)(i%26)); - t = libnet_build_icmpv4_echo(ICMP6_ECHO,0,0,1,0,payload,sizeof(payload),l,t); + t = libnet_build_icmpv4_echo(ICMP6_ECHO,0,0,1,0,(uint8_t *)payload,sizeof(payload),l,t); if (build_ip) { @@ -181,4 +181,3 @@ usage(char *nomenclature) } -/* EOF */