svn commit: r247863 - head/usr.sbin/rtadvd

Hiroki Sato hrs at FreeBSD.org
Wed Mar 6 04:58:49 UTC 2013


Author: hrs
Date: Wed Mar  6 04:58:48 2013
New Revision: 247863
URL: http://svnweb.freebsd.org/changeset/base/247863

Log:
  Fix SIGSEGV when set_short_delay() is called when ifi->ifi_ra_timer is NULL.
  This can happen in a short period when a prefix is changed by a rtmsg and a
  new interface arrives.

Modified:
  head/usr.sbin/rtadvd/rtadvd.c

Modified: head/usr.sbin/rtadvd/rtadvd.c
==============================================================================
--- head/usr.sbin/rtadvd/rtadvd.c	Wed Mar  6 01:21:56 2013	(r247862)
+++ head/usr.sbin/rtadvd/rtadvd.c	Wed Mar  6 04:58:48 2013	(r247863)
@@ -1008,6 +1008,8 @@ set_short_delay(struct ifinfo *ifi)
 	long delay;	/* must not be greater than 1000000 */
 	struct timeval interval, now, min_delay, tm_tmp, *rest;
 
+	if (ifi->ifi_ra_timer == NULL)
+		return;
 	/*
 	 * Compute a random delay. If the computed value
 	 * corresponds to a time later than the time the next


More information about the svn-src-all mailing list