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 6606F1386E9 for ; Sun, 27 Jan 2013 18:57:00 +0000 (UTC) Received: from pigeon.gentoo.org (localhost [127.0.0.1]) by pigeon.gentoo.org (Postfix) with SMTP id 693E021C033; Sun, 27 Jan 2013 18:56:59 +0000 (UTC) Received: from smtp.gentoo.org (smtp.gentoo.org [140.211.166.183]) (using TLSv1 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by pigeon.gentoo.org (Postfix) with ESMTPS id DC7DD21C010 for ; Sun, 27 Jan 2013 18:56:58 +0000 (UTC) Received: from hornbill.gentoo.org (hornbill.gentoo.org [94.100.119.163]) (using TLSv1 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by smtp.gentoo.org (Postfix) with ESMTPS id BEE6A33DB40 for ; Sun, 27 Jan 2013 18:56:57 +0000 (UTC) Received: from localhost.localdomain (localhost [127.0.0.1]) by hornbill.gentoo.org (Postfix) with ESMTP id 7B845E4089 for ; Sun, 27 Jan 2013 18:56:55 +0000 (UTC) From: "William Hubbs" To: gentoo-commits@lists.gentoo.org Content-Transfer-Encoding: 8bit Content-type: text/plain; charset=UTF-8 Reply-To: gentoo-dev@lists.gentoo.org, "William Hubbs" Message-ID: <1359312925.72685c836e468e6de8db0da83a32dbde448c4d22.WilliamH@gentoo> Subject: [gentoo-commits] proj/udev-gentoo-scripts:master commit in: init.d/ X-VCS-Repository: proj/udev-gentoo-scripts X-VCS-Files: init.d/udev X-VCS-Directories: init.d/ X-VCS-Committer: WilliamH X-VCS-Committer-Name: William Hubbs X-VCS-Revision: 72685c836e468e6de8db0da83a32dbde448c4d22 X-VCS-Branch: master Date: Sun, 27 Jan 2013 18:56:55 +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: 7ba65f34-7ae6-4dff-a925-5bede38ff0c4 X-Archives-Hash: 74f49fde140f7f6c74e0f334cb18a9db commit: 72685c836e468e6de8db0da83a32dbde448c4d22 Author: William Hubbs gentoo org> AuthorDate: Sun Jan 27 18:55:25 2013 +0000 Commit: William Hubbs gentoo org> CommitDate: Sun Jan 27 18:55:25 2013 +0000 URL: http://git.overlays.gentoo.org/gitweb/?p=proj/udev-gentoo-scripts.git;a=commit;h=72685c83 move disable_oldnet_hotplug above start_pre This function is used in start_pre, so move it to reflect that. Code is easier to follow if it is defined before it is used. --- init.d/udev | 26 +++++++++++++------------- 1 files changed, 13 insertions(+), 13 deletions(-) diff --git a/init.d/udev b/init.d/udev index 0a95873..193adf7 100644 --- a/init.d/udev +++ b/init.d/udev @@ -70,6 +70,19 @@ check_kernel() return 0 } +disable_oldnet_hotplug() +{ + if is_service_enabled network; then + # disable network hotplugging + local d="/run/udev/rules.d" + mkdir -p "${d}" + local f="${d}/90-network.rules" + echo "# This file disables network hotplug events calling" >> "${f}" + echo "# old-style openrc net scripts" >> "${f}" + echo "# as we use /etc/init.d/network to set up our network" >> "${f}" + fi +} + start_pre() { check_kernel || return 1 @@ -118,19 +131,6 @@ is_service_enabled() return 1 } -disable_oldnet_hotplug() -{ - if is_service_enabled network; then - # disable network hotplugging - local d="/run/udev/rules.d" - mkdir -p "${d}" - local f="${d}/90-network.rules" - echo "# This file disables network hotplug events calling" >> "${f}" - echo "# old-style openrc net scripts" >> "${f}" - echo "# as we use /etc/init.d/network to set up our network" >> "${f}" - fi -} - start_udevmonitor() { yesno "${udev_monitor}" || return 0