[arch-projects] [initscripts][PATCH 1/3] rc.sysinit: avoid exporting empty TIMEZONE as TZ
fixes FS#28458 Signed-off-by: Dave Reisner <dreisner@archlinux.org> --- rc.sysinit | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/rc.sysinit b/rc.sysinit index 88c72a0..b38d350 100755 --- a/rc.sysinit +++ b/rc.sysinit @@ -64,7 +64,9 @@ if [[ $HWCLOCK_PARAMS ]]; then # is used. If HARDWARECLOCK is not set in rc.conf, the value in # /var/lib/hwclock/adjfile is used (in this case /var can not be a separate # partition). - TZ=$TIMEZONE hwclock $HWCLOCK_PARAMS && stat_done || stat_fail + [[ $TIMEZONE ]] && export TZ=$TIMEZONE + hwclock $HWCLOCK_PARAMS && stat_done || stat_fail + unset TZ fi # Start/trigger UDev, load MODULES and settle UDev -- 1.7.9.2
This avoids passing an empty array to umount Signed-off-by: Dave Reisner <dreisner@archlinux.org> --- functions | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/functions b/functions index 833711b..a3c2660 100644 --- a/functions +++ b/functions @@ -505,7 +505,9 @@ umount_all() { mounts=("$target" "${mounts[@]}") done < <(findmnt -mrunRo TARGET,FSTYPE,OPTIONS /) - umount -r "${mounts[@]}" + if (( ${#mounts[*]} )); then + umount -r "${mounts[@]}" + fi } -- 1.7.9.2
Avoid unnecessary output about sending a SIGTERM to the active PID. Signed-off-by: Dave Reisner <dreisner@archlinux.org> --- network | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/network b/network index faaac78..2439dba 100755 --- a/network +++ b/network @@ -52,7 +52,7 @@ network_down() { have_interface "$interface" || return 1 if [[ -f /run/dhcpcd-$interface.pid ]]; then - dhcpcd -k $interface || return 1 + dhcpcd -qk $interface || return 1 else ip addr flush dev $interface || return 1 fi -- 1.7.9.2
Thanks! Pulled all three. -t
participants (2)
-
Dave Reisner
-
Tom Gundersen