Skip site navigation (1)Skip section navigation (2)
Date:      Sat, 17 Aug 2013 07:14:46 +0000 (UTC)
From:      Hiroki Sato <hrs@FreeBSD.org>
To:        src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org
Subject:   svn commit: r254441 - head/sys/netinet6
Message-ID:  <201308170714.r7H7Ekim089970@svn.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: hrs
Date: Sat Aug 17 07:14:45 2013
New Revision: 254441
URL: http://svnweb.freebsd.org/changeset/base/254441

Log:
  Return 0 in nbi->expire when la_expire == 0.  Conversion from time_uptime to
  time_second should not be performed in this case.

Modified:
  head/sys/netinet6/nd6.c

Modified: head/sys/netinet6/nd6.c
==============================================================================
--- head/sys/netinet6/nd6.c	Sat Aug 17 07:12:52 2013	(r254440)
+++ head/sys/netinet6/nd6.c	Sat Aug 17 07:14:45 2013	(r254441)
@@ -1508,7 +1508,11 @@ nd6_ioctl(u_long cmd, caddr_t data, stru
 		nbi->state = ln->ln_state;
 		nbi->asked = ln->la_asked;
 		nbi->isrouter = ln->ln_router;
-		nbi->expire = ln->la_expire + (time_second - time_uptime);
+		if (ln->la_expire == 0)
+			nbi->expire = 0;
+		else
+			nbi->expire = ln->la_expire +
+			    (time_second - time_uptime);
 		LLE_RUNLOCK(ln);
 		break;
 	}



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201308170714.r7H7Ekim089970>