Module Name:    src
Committed By:   joerg
Date:           Thu Jun 12 22:15:25 UTC 2014

Modified Files:
        src/external/bsd/ipf/dist/lib: gethost.c
        src/external/bsd/ipf/dist/tools: ipnat_y.y

Log Message:
Fix build.


To generate a diff of this commit:
cvs rdiff -u -r1.3 -r1.4 src/external/bsd/ipf/dist/lib/gethost.c
cvs rdiff -u -r1.2 -r1.3 src/external/bsd/ipf/dist/tools/ipnat_y.y

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: src/external/bsd/ipf/dist/lib/gethost.c
diff -u src/external/bsd/ipf/dist/lib/gethost.c:1.3 src/external/bsd/ipf/dist/lib/gethost.c:1.4
--- src/external/bsd/ipf/dist/lib/gethost.c:1.3	Thu Jun 12 17:23:06 2014
+++ src/external/bsd/ipf/dist/lib/gethost.c	Thu Jun 12 22:15:25 2014
@@ -1,4 +1,4 @@
-/*	$NetBSD: gethost.c,v 1.3 2014/06/12 17:23:06 christos Exp $	*/
+/*	$NetBSD: gethost.c,v 1.4 2014/06/12 22:15:25 joerg Exp $	*/
 
 /*
  * Copyright (C) 2012 by Darren Reed.
@@ -19,7 +19,7 @@ int gethost(family, name, hostp)
 	struct netent *n;
 	u_32_t addr;
 
-	memset(hostp, sizeof(*hostp));
+	memset(hostp, 0, sizeof(*hostp));
 	if (!strcmp(name, "test.host.dots")) {
 		if (family == AF_INET) {
 			hostp->in4.s_addr = htonl(0xfedcba98);
@@ -60,7 +60,7 @@ int gethost(family, name, hostp)
 		struct addrinfo hints, *res;
 		struct sockaddr_in6 *sin6;
 
-		memset(&hints, sizeof(hints));
+		memset(&hints, 0, sizeof(hints));
 		hints.ai_family = PF_INET6;
 
 		getaddrinfo(name, NULL, &hints, &res);

Index: src/external/bsd/ipf/dist/tools/ipnat_y.y
diff -u src/external/bsd/ipf/dist/tools/ipnat_y.y:1.2 src/external/bsd/ipf/dist/tools/ipnat_y.y:1.3
--- src/external/bsd/ipf/dist/tools/ipnat_y.y:1.2	Thu Jun 12 17:23:06 2014
+++ src/external/bsd/ipf/dist/tools/ipnat_y.y	Thu Jun 12 22:15:25 2014
@@ -1,4 +1,4 @@
-/*	$NetBSD: ipnat_y.y,v 1.2 2014/06/12 17:23:06 christos Exp $	*/
+/*	$NetBSD: ipnat_y.y,v 1.3 2014/06/12 22:15:25 joerg Exp $	*/
 
 /*
  * Copyright (C) 2012 by Darren Reed.
@@ -1763,7 +1763,7 @@ addname(np, name)
 
 	nlen = strlen(name) + 1;
 	n = calloc(1, (*np)->in_size + nlen);
-	memcpy(n, *np (*np)->in_size);
+	memcpy(n, *np, (*np)->in_size);
 	free(*np);
 	if (*np == nattop)
 		nattop = n;

Reply via email to