Module Name:    src
Committed By:   vanhu
Date:           Thu Aug 26 13:31:56 UTC 2010

Modified Files:
        src/crypto/dist/ipsec-tools/src/racoon: remoteconf.c

Log Message:
fix by Sergio.Gelato (at) astro.su.se: duplicate some dynamic values in 
duprmconf()


To generate a diff of this commit:
cvs rdiff -u -r1.19 -r1.20 \
    src/crypto/dist/ipsec-tools/src/racoon/remoteconf.c

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

Modified files:

Index: src/crypto/dist/ipsec-tools/src/racoon/remoteconf.c
diff -u src/crypto/dist/ipsec-tools/src/racoon/remoteconf.c:1.19 src/crypto/dist/ipsec-tools/src/racoon/remoteconf.c:1.20
--- src/crypto/dist/ipsec-tools/src/racoon/remoteconf.c:1.19	Tue Jun 22 09:41:33 2010
+++ src/crypto/dist/ipsec-tools/src/racoon/remoteconf.c	Thu Aug 26 13:31:55 2010
@@ -1,4 +1,4 @@
-/*	$NetBSD: remoteconf.c,v 1.19 2010/06/22 09:41:33 vanhu Exp $	*/
+/*	$NetBSD: remoteconf.c,v 1.20 2010/08/26 13:31:55 vanhu Exp $	*/
 
 /* Id: remoteconf.c,v 1.38 2006/05/06 15:52:44 manubsd Exp */
 
@@ -555,6 +555,24 @@
 	new->idvl_p = genlist_init();
 	genlist_foreach(rmconf->idvl_p, dupidvl, new->idvl_p);
 
+        /* duplicate strings */ 
+	if (new->mycertfile != NULL) { 
+		new->mycertfile = racoon_strdup(new->mycertfile); 
+		STRDUP_FATAL(new->mycertfile); 
+	} 
+	if (new->myprivfile != NULL) { 
+		new->myprivfile = racoon_strdup(new->myprivfile); 
+		STRDUP_FATAL(new->myprivfile); 
+	} 
+	if (new->peerscertfile != NULL) { 
+		new->peerscertfile = racoon_strdup(new->peerscertfile); 
+		STRDUP_FATAL(new->peerscertfile); 
+	} 
+	if (new->cacertfile != NULL) { 
+                new->cacertfile = racoon_strdup(new->cacertfile); 
+		STRDUP_FATAL(new->cacertfile); 
+	} 
+
 	return new;
 }
 

Reply via email to