Date: Thu, 11 Dec 2014 00:41:55 +0000 (UTC) From: Mark Johnston <markj@FreeBSD.org> To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r275695 - head/sys/netinet6 Message-ID: <201412110041.sBB0ftwC030057@svn.freebsd.org>
next in thread | raw e-mail | index | archive | help
Author: markj Date: Thu Dec 11 00:41:54 2014 New Revision: 275695 URL: https://svnweb.freebsd.org/changeset/base/275695 Log: Fix a bug in r266857: nd6_dad_find() must return NULL if it doesn't find a matching element in the DAD queue. Reported by: Holger Hans Peter Freyther <holger@freyther.de> MFC after: 3 days Modified: head/sys/netinet6/nd6_nbr.c Modified: head/sys/netinet6/nd6_nbr.c ============================================================================== --- head/sys/netinet6/nd6_nbr.c Thu Dec 11 00:25:26 2014 (r275694) +++ head/sys/netinet6/nd6_nbr.c Thu Dec 11 00:41:54 2014 (r275695) @@ -1210,11 +1210,12 @@ nd6_dad_find(struct ifaddr *ifa) TAILQ_FOREACH(dp, &V_dadq, dad_list) if (dp->dad_ifa == ifa) { refcount_acquire(&dp->dad_refcnt); - break; + DADQ_RUNLOCK(); + return (dp); } DADQ_RUNLOCK(); - return (dp); + return (NULL); } static void
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201412110041.sBB0ftwC030057>