From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from lists.gentoo.org (pigeon.gentoo.org [208.92.234.80]) by finch.gentoo.org (Postfix) with ESMTP id 276E213838B for ; Wed, 24 Sep 2014 06:19:56 +0000 (UTC) Received: from pigeon.gentoo.org (localhost [127.0.0.1]) by pigeon.gentoo.org (Postfix) with SMTP id 1BFDEE088F; Wed, 24 Sep 2014 06:19:55 +0000 (UTC) Received: from smtp.gentoo.org (smtp.gentoo.org [140.211.166.183]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by pigeon.gentoo.org (Postfix) with ESMTPS id CB0D7E088F for ; Wed, 24 Sep 2014 06:19:54 +0000 (UTC) Received: from oystercatcher.gentoo.org (oystercatcher.gentoo.org [148.251.78.52]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by smtp.gentoo.org (Postfix) with ESMTPS id 0344B335DE5 for ; Wed, 24 Sep 2014 06:19:54 +0000 (UTC) Received: from localhost.localdomain (localhost [127.0.0.1]) by oystercatcher.gentoo.org (Postfix) with ESMTP id 5242D61AB for ; Wed, 24 Sep 2014 06:19:52 +0000 (UTC) From: "Robin H. Johnson" To: gentoo-commits@lists.gentoo.org Content-Transfer-Encoding: 8bit Content-type: text/plain; charset=UTF-8 Reply-To: gentoo-dev@lists.gentoo.org, "Robin H. Johnson" Message-ID: <1411539572.42aa70384a89346dd1733dfff4131f56178dc26a.robbat2@OpenRC> Subject: [gentoo-commits] proj/netifrc:master commit in: net/ X-VCS-Repository: proj/netifrc X-VCS-Files: net/dhcpcd.sh X-VCS-Directories: net/ X-VCS-Committer: robbat2 X-VCS-Committer-Name: Robin H. Johnson X-VCS-Revision: 42aa70384a89346dd1733dfff4131f56178dc26a X-VCS-Branch: master Date: Wed, 24 Sep 2014 06:19:52 +0000 (UTC) Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: List-Id: Gentoo Linux mail X-BeenThere: gentoo-commits@lists.gentoo.org X-Archives-Salt: 262933cc-ce46-4eec-b557-47dca520864a X-Archives-Hash: 85476914df74379178494f784fb4771c commit: 42aa70384a89346dd1733dfff4131f56178dc26a Author: Nuno Silva (njsg) iki fi> AuthorDate: Sat Sep 20 06:53:59 2014 +0000 Commit: Robin H. Johnson gentoo org> CommitDate: Wed Sep 24 06:19:32 2014 +0000 URL: http://sources.gentoo.org/gitweb/?p=proj/netifrc.git;a=commit;h=42aa7038 Use dhcpcd -k to force the release, instead of SIGHUP Newer dhcpcd versions use a different signal internally (SIGALRM), but dhcpcd -k interface_name will work with both newer and older versions of dhcpcd. Signed-off-by: Robin H. Johnson gentoo.org> --- net/dhcpcd.sh | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/net/dhcpcd.sh b/net/dhcpcd.sh index 2c0f919..bdb60c6 100644 --- a/net/dhcpcd.sh +++ b/net/dhcpcd.sh @@ -81,8 +81,11 @@ dhcpcd_stop() eval opts=\$dhcp_${IFVAR} [ -z "${opts}" ] && opts=${dhcp} case " ${opts} " in - *" release "*) sig=SIGHUP;; + *" release "*) dhcpcd -k "${IFACE}" ;; + *) + start-stop-daemon --stop --quiet \ + --signal ${sig} --pidfile "${pidfile}" + ;; esac - start-stop-daemon --stop --quiet --signal ${sig} --pidfile "${pidfile}" eend $? }