Module Name:    src
Committed By:   martin
Date:           Wed May 29 15:57:38 UTC 2019

Modified Files:
        src/sys/netipsec [netbsd-8]: ipsecif.c

Log Message:
Pull up following revision(s) (requested by knakahara in ticket #1273):

        sys/netipsec/ipsecif.c: revision 1.16

Don't clear calculated Tx tos value for IPv[46] over IPv6.


To generate a diff of this commit:
cvs rdiff -u -r1.1.2.7 -r1.1.2.8 src/sys/netipsec/ipsecif.c

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

Modified files:

Index: src/sys/netipsec/ipsecif.c
diff -u src/sys/netipsec/ipsecif.c:1.1.2.7 src/sys/netipsec/ipsecif.c:1.1.2.8
--- src/sys/netipsec/ipsecif.c:1.1.2.7	Thu May 17 14:07:03 2018
+++ src/sys/netipsec/ipsecif.c	Wed May 29 15:57:38 2019
@@ -1,4 +1,4 @@
-/*	$NetBSD: ipsecif.c,v 1.1.2.7 2018/05/17 14:07:03 martin Exp $  */
+/*	$NetBSD: ipsecif.c,v 1.1.2.8 2019/05/29 15:57:38 martin Exp $  */
 
 /*
  * Copyright (c) 2017 Internet Initiative Japan Inc.
@@ -27,7 +27,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: ipsecif.c,v 1.1.2.7 2018/05/17 14:07:03 martin Exp $");
+__KERNEL_RCSID(0, "$NetBSD: ipsecif.c,v 1.1.2.8 2019/05/29 15:57:38 martin Exp $");
 
 #ifdef _KERNEL_OPT
 #include "opt_inet.h"
@@ -557,13 +557,13 @@ ipsecif6_output(struct ipsec_variant *va
 		return ENETUNREACH;
 	}
 #ifndef IPSEC_TX_TOS_CLEAR
+	if (!ip6_ipsec_copy_tos)
+		otos = 0;
+
 	if (ifp->if_flags & IFF_ECN)
 		ip_ecn_ingress(ECN_ALLOWED, &otos, &itos);
 	else
 		ip_ecn_ingress(ECN_NOCARE, &otos, &itos);
-
-	if (!ip6_ipsec_copy_tos)
-		otos = 0;
 #else
 	if (ip6_ipsec_copy_tos)
 		otos = itos;

Reply via email to