From owner-svn-src-all@FreeBSD.ORG Sat Sep 12 23:00:02 2009 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 4352B1065676; Sat, 12 Sep 2009 23:00:02 +0000 (UTC) (envelope-from hrs@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 2D8EF8FC13; Sat, 12 Sep 2009 23:00:02 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id n8CN02sl000132; Sat, 12 Sep 2009 23:00:02 GMT (envelope-from hrs@svn.freebsd.org) Received: (from hrs@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id n8CN02Gm000130; Sat, 12 Sep 2009 23:00:02 GMT (envelope-from hrs@svn.freebsd.org) Message-Id: <200909122300.n8CN02Gm000130@svn.freebsd.org> From: Hiroki Sato Date: Sat, 12 Sep 2009 23:00:02 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r197146 - head/etc/rc.d X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 12 Sep 2009 23:00:02 -0000 Author: hrs Date: Sat Sep 12 23:00:01 2009 New Revision: 197146 URL: http://svn.freebsd.org/changeset/base/197146 Log: Use is_wired_interface() instead of hard-coded interface device names. Pointed out by: sam Modified: head/etc/rc.d/rtadvd Modified: head/etc/rc.d/rtadvd ============================================================================== --- head/etc/rc.d/rtadvd Sat Sep 12 22:22:31 2009 (r197145) +++ head/etc/rc.d/rtadvd Sat Sep 12 23:00:01 2009 (r197146) @@ -9,6 +9,7 @@ # KEYWORD: nojail shutdown . /etc/rc.subr +. /etc/network.subr name="rtadvd" rcvar=`set_rcvar` @@ -42,29 +43,9 @@ rtadvd_precmd() case ${rtadvd_interfaces} in [Aa][Uu][Tt][Oo]|'') for i in `ifconfig -l` ; do - case $i in - lo0|\ - stf[0-9]*|\ - faith[0-9]*|\ - lp[0-9]*|\ - sl[0-9]*|\ - pflog[0-9]*|\ - pfsync[0-9]*|\ - an[0-9]*|\ - ath[0-9]*|\ - ipw[0-9]*|\ - iwi[0-9]*|\ - iwn[0-9]*|\ - ral[0-9]*|\ - wi[0-9]*|\ - wl[0-9]*|\ - wpi[0-9]*) - continue - ;; - *) + if is_wired_interface $1; then rtadvd_interfaces="${rtadvd_interfaces} ${i}" - ;; - esac + fi done ;; esac