From 0e74c109570143a0dd515c80b8630180b0ebc12f Mon Sep 17 00:00:00 2001 From: sevan Date: Sat, 5 Oct 2019 22:21:29 +0000 Subject: [PATCH] No need to empose the script to be runnable during boot time, it prevents the script from wroking if the system is booted into single user mode & then moved onto multi-user mode. Reported by for NPF but the issue is there in PF too. --- etc/rc.d/npf_boot | 6 +----- etc/rc.d/pf_boot | 6 +----- 2 files changed, 2 insertions(+), 10 deletions(-) diff --git a/etc/rc.d/npf_boot b/etc/rc.d/npf_boot index 2a419b8df48e..eca0cdc62c4d 100644 --- a/etc/rc.d/npf_boot +++ b/etc/rc.d/npf_boot @@ -1,6 +1,6 @@ #!/bin/sh # -# $NetBSD: npf_boot,v 1.1 2019/04/02 01:50:32 sevan Exp $ +# $NetBSD: npf_boot,v 1.2 2019/10/05 22:21:29 sevan Exp $ # # PROVIDE: npf_boot @@ -16,10 +16,6 @@ stop_cmd=":" npf_boot_start() { - if [ "$autoboot" != "yes" ]; then - err 1 "This script should only be executed at boot time." - fi - if [ -f /etc/npf.boot.conf ]; then /sbin/npfctl reload /etc/npf.boot.conf elif [ -f /etc/defaults/npf.boot.conf ]; then diff --git a/etc/rc.d/pf_boot b/etc/rc.d/pf_boot index 1a481b134b62..f6b185fc53c4 100755 --- a/etc/rc.d/pf_boot +++ b/etc/rc.d/pf_boot @@ -1,6 +1,6 @@ #!/bin/sh # -# $NetBSD: pf_boot,v 1.4 2008/11/22 20:23:33 tsutsui Exp $ +# $NetBSD: pf_boot,v 1.5 2019/10/05 22:21:29 sevan Exp $ # # PROVIDE: pf_boot @@ -16,10 +16,6 @@ stop_cmd=":" pf_boot_start() { - if [ "$autoboot" != "yes" ]; then - err 1 "This script should only be executed at boot time." - fi - if [ -f /etc/pf.boot.conf ]; then /sbin/pfctl -q -f /etc/pf.boot.conf elif [ -f /etc/defaults/pf.boot.conf ]; then