aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--lib/libnet/icmpv6.c18
-rw-r--r--lib/libnet/ipv6.c3
-rw-r--r--lib/libnet/netload.c4
3 files changed, 11 insertions, 14 deletions
diff --git a/lib/libnet/icmpv6.c b/lib/libnet/icmpv6.c
index 2e0cf7c..d44ce84 100644
--- a/lib/libnet/icmpv6.c
+++ b/lib/libnet/icmpv6.c
@@ -230,11 +230,10 @@ send_neighbour_solicitation (int fd, ip6_addr_t *dest_ip6)
snma.addr[13] = dest_ip6->addr[13];
snma.addr[14] = dest_ip6->addr[14];
snma.addr[15] = dest_ip6->addr[15];
- fill_ip6hdr((uint8_t *) headers.ip6h,
- ICMPv6_HEADER_SIZE +
- sizeof(struct neighbour_solicitation),
- 0x3a, //ICMPv6
- get_ipv6_address(), &snma);
+ fill_ip6hdr((uint8_t *) headers.ip6h,
+ ICMPv6_HEADER_SIZE + sizeof(struct neighbour_solicitation),
+ 0x3a, //ICMPv6
+ get_ipv6_address(), &snma);
/* Fill ICMPv6 message */
headers.icmp6h->type = ICMPV6_NEIGHBOUR_SOLICITATION;
@@ -280,11 +279,10 @@ send_neighbour_advertisement (int fd, struct neighbor *target)
sizeof(struct ip6hdr));
/* Fill IPv6 header */
- fill_ip6hdr(ether_packet + sizeof(struct ethhdr),
- ICMPv6_HEADER_SIZE +
- sizeof(struct neighbour_advertisement),
- 0x3a, //ICMPv6
- get_ipv6_address(), (ip6_addr_t *) &(target->ip.addr));
+ fill_ip6hdr(ether_packet + sizeof(struct ethhdr),
+ ICMPv6_HEADER_SIZE + sizeof(struct neighbour_advertisement),
+ 0x3a, //ICMPv6
+ get_ipv6_address(), (ip6_addr_t *) &(target->ip.addr));
/* Fill ICMPv6 message */
memcpy( &(headers.icmp6h->icmp6body.nghb_adv.target),
diff --git a/lib/libnet/ipv6.c b/lib/libnet/ipv6.c
index 49de5c7..62a444e 100644
--- a/lib/libnet/ipv6.c
+++ b/lib/libnet/ipv6.c
@@ -32,7 +32,6 @@
#endif
/****************************** PROTOTYPES *******************************/
-int8_t ip6addr_add (struct ip6addr_list_entry *new_address);
static void ipv6_init(int fd);
static int ip6_is_multicast (ip6_addr_t * ip);
@@ -252,7 +251,7 @@ int8_t unknown_prefix(ip6_addr_t *ip)
* @return NULL - malloc failed
* ! NULL - pointer to new prefix_info
*/
-struct prefix_info *ip6_create_prefix_info()
+struct prefix_info *ip6_create_prefix_info(void)
{
struct prefix_info *prfx_info;
diff --git a/lib/libnet/netload.c b/lib/libnet/netload.c
index 848609d..cd3720a 100644
--- a/lib/libnet/netload.c
+++ b/lib/libnet/netload.c
@@ -856,8 +856,8 @@ int parse_tftp_args(char buffer[], char *server_ip, char filename[], int fd,
strcpy(domainname, tmp);
if (dns_get_ip(fd, domainname, server_ip6, 6) == 0) {
printf("\n DNS failed for IPV6\n");
- return -1;
- }
+ return -1;
+ }
ipv6_to_str(server_ip6, server_ip);
strcpy(filename,(tmp1+1));