Browse Source

dash compat: use "2>&1" rather than "&>"

master
Harald Hoyer 13 years ago
parent
commit
aa09b74a41
  1. 2
      modules.d/04watchdog/watchdog.sh
  2. 4
      modules.d/90mdraid/module-setup.sh
  3. 4
      modules.d/90qemu-net/module-setup.sh
  4. 4
      modules.d/90qemu/module-setup.sh
  5. 2
      modules.d/96securityfs/securityfs.sh

2
modules.d/04watchdog/watchdog.sh

@ -1,7 +1,7 @@ @@ -1,7 +1,7 @@
#!/bin/sh
if [ -e /dev/watchdog ]; then
if [ ! -e /tmp/watchdog_timeout ]; then
wdctl -s 60 /dev/watchdog &>/dev/null
wdctl -s 60 /dev/watchdog >/dev/null 2>&1
> /tmp/watchdog_timeout
fi
info "Triggering watchdog"

4
modules.d/90mdraid/module-setup.sh

@ -66,10 +66,10 @@ install() { @@ -66,10 +66,10 @@ install() {
inst_rules "$moddir/65-md-incremental-imsm.rules"

# guard against pre-3.0 mdadm versions, that can't handle containers
if ! mdadm -Q -e imsm /dev/null &> /dev/null; then
if ! mdadm -Q -e imsm /dev/null >/dev/null 2>&1; then
inst_hook pre-trigger 30 "$moddir/md-noimsm.sh"
fi
if ! mdadm -Q -e ddf /dev/null &> /dev/null; then
if ! mdadm -Q -e ddf /dev/null >/dev/null 2>&1; then
inst_hook pre-trigger 30 "$moddir/md-noddf.sh"
fi


4
modules.d/90qemu-net/module-setup.sh

@ -3,8 +3,8 @@ @@ -3,8 +3,8 @@
# ex: ts=8 sw=4 sts=4 et filetype=sh

check() {
if type -P systemd-detect-virt &>/dev/null; then
vm=$(systemd-detect-virt --vm &>/dev/null)
if type -P systemd-detect-virt >/dev/null 2>&1; then
vm=$(systemd-detect-virt --vm >/dev/null 2>&1)
(($? != 0)) && return 255
[[ $vm = "qemu" ]] && return 0
[[ $vm = "kvm" ]] && return 0

4
modules.d/90qemu/module-setup.sh

@ -3,8 +3,8 @@ @@ -3,8 +3,8 @@
# ex: ts=8 sw=4 sts=4 et filetype=sh

check() {
if type -P systemd-detect-virt &>/dev/null; then
vm=$(systemd-detect-virt --vm &>/dev/null)
if type -P systemd-detect-virt >/dev/null 2>&1; then
vm=$(systemd-detect-virt --vm >/dev/null 2>&1)
(($? != 0)) && return 255
[[ $vm = "qemu" ]] && return 0
[[ $vm = "kvm" ]] && return 0

2
modules.d/96securityfs/securityfs.sh

@ -5,6 +5,6 @@ @@ -5,6 +5,6 @@
SECURITYFSDIR="/sys/kernel/security"
export SECURITYFSDIR

if ! ismounted "${SECURITYFSDIR}"; then
if ! findmnt "${SECURITYFSDIR}" >/dev/null 2>&1; then
mount -t securityfs -o nosuid,noexec,nodev securityfs ${SECURITYFSDIR} >/dev/null 2>&1
fi

Loading…
Cancel
Save