Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/trunk]: src/sys/netinet avoid double rtcache_unref().



details:   https://anonhg.NetBSD.org/src/rev/7815b19596b4
branches:  trunk
changeset: 820457:7815b19596b4
user:      knakahara <knakahara%NetBSD.org@localhost>
date:      Tue Jan 10 07:39:52 2017 +0000

description:
avoid double rtcache_unref().

reviewed by ozaki-r@n.o.

diffstat:

 sys/netinet/ip_output.c |  5 +++--
 1 files changed, 3 insertions(+), 2 deletions(-)

diffs (26 lines):

diff -r 4eb95998f9cc -r 7815b19596b4 sys/netinet/ip_output.c
--- a/sys/netinet/ip_output.c   Tue Jan 10 07:34:04 2017 +0000
+++ b/sys/netinet/ip_output.c   Tue Jan 10 07:39:52 2017 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: ip_output.c,v 1.265 2016/12/12 03:55:57 ozaki-r Exp $  */
+/*     $NetBSD: ip_output.c,v 1.266 2017/01/10 07:39:52 knakahara Exp $        */
 
 /*
  * Copyright (C) 1995, 1996, 1997, and 1998 WIDE Project.
@@ -91,7 +91,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: ip_output.c,v 1.265 2016/12/12 03:55:57 ozaki-r Exp $");
+__KERNEL_RCSID(0, "$NetBSD: ip_output.c,v 1.266 2017/01/10 07:39:52 knakahara Exp $");
 
 #ifdef _KERNEL_OPT
 #include "opt_inet.h"
@@ -363,6 +363,7 @@
                }
                if (ifa_is_destroying(rt->rt_ifa)) {
                        rtcache_unref(rt, ro);
+                       rt = NULL;
                        IP_STATINC(IP_STAT_NOROUTE);
                        error = EHOSTUNREACH;
                        goto bad;



Home | Main Index | Thread Index | Old Index