From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from lists.gentoo.org (pigeon.gentoo.org [208.92.234.80]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by finch.gentoo.org (Postfix) with ESMTPS id 23DCB138359 for ; Fri, 6 Nov 2020 00:29:44 +0000 (UTC) Received: from pigeon.gentoo.org (localhost [127.0.0.1]) by pigeon.gentoo.org (Postfix) with SMTP id 3834AE0831; Fri, 6 Nov 2020 00:29:43 +0000 (UTC) Received: from smtp.gentoo.org (smtp.gentoo.org [140.211.166.183]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by pigeon.gentoo.org (Postfix) with ESMTPS id 0426EE0831 for ; Fri, 6 Nov 2020 00:29:42 +0000 (UTC) Received: from oystercatcher.gentoo.org (oystercatcher.gentoo.org [148.251.78.52]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.gentoo.org (Postfix) with ESMTPS id 46B8B340BCD for ; Fri, 6 Nov 2020 00:29:41 +0000 (UTC) Received: from localhost.localdomain (localhost [IPv6:::1]) by oystercatcher.gentoo.org (Postfix) with ESMTP id 791823F6 for ; Fri, 6 Nov 2020 00:29:39 +0000 (UTC) From: "Matt Turner" To: gentoo-commits@lists.gentoo.org Content-Transfer-Encoding: 8bit Content-type: text/plain; charset=UTF-8 Reply-To: gentoo-dev@lists.gentoo.org, "Matt Turner" Message-ID: <1604622547.58948705bcf5136401621a8855e9f0c15049e1dd.mattst88@gentoo> Subject: [gentoo-commits] proj/livecd-tools:master commit in: init.d/ X-VCS-Repository: proj/livecd-tools X-VCS-Files: init.d/autoconfig X-VCS-Directories: init.d/ X-VCS-Committer: mattst88 X-VCS-Committer-Name: Matt Turner X-VCS-Revision: 58948705bcf5136401621a8855e9f0c15049e1dd X-VCS-Branch: master Date: Fri, 6 Nov 2020 00:29:39 +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-Auto-Response-Suppress: DR, RN, NRN, OOF, AutoReply X-Archives-Salt: e592f169-b142-4474-af84-06b52ecc4250 X-Archives-Hash: a23df08c4dadfe45325b5fefdf097a2b commit: 58948705bcf5136401621a8855e9f0c15049e1dd Author: Matt Turner gentoo org> AuthorDate: Fri Nov 6 00:27:40 2020 +0000 Commit: Matt Turner gentoo org> CommitDate: Fri Nov 6 00:29:07 2020 +0000 URL: https://gitweb.gentoo.org/proj/livecd-tools.git/commit/?id=58948705 autoconfig: Fix logic error When the system starts, the PID file will not exist because we haven't started dhcpcd. Also update /var/run -> /run while we're here. Closes: https://bugs.gentoo.org/198083 Closes: https://bugs.gentoo.org/439912 Signed-off-by: Matt Turner gentoo.org> init.d/autoconfig | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/init.d/autoconfig b/init.d/autoconfig index 15900c2..f475813 100644 --- a/init.d/autoconfig +++ b/init.d/autoconfig @@ -529,9 +529,9 @@ start() { if yesno "${DHCP}" then einfo "DHCP broadcasting for IP on all detected interfaces ..." - if [ -f /var/run/dhcpcd.pid ] + if [ ! -f /run/dhcpcd.pid ] then - kill $(cat /var/run/dhcpcd.pid) + kill $(cat /run/dhcpcd.pid) sleep 2 fi dhcpcd -n -h $(hostname)