From 7526db5d0405188fee94d16fbcfbdf13a17e6a45 Mon Sep 17 00:00:00 2001 From: Roman Kyrylych Date: Sun, 9 Mar 2008 17:22:11 +0200 Subject: More full-path fixes Signed-off-by: Roman Kyrylych --- network | 10 +++++----- rc.single | 2 +- rc.sysinit | 24 ++++++++++++------------ 3 files changed, 18 insertions(+), 18 deletions(-) diff --git a/network b/network index 81996ef..d65e861 100755 --- a/network +++ b/network @@ -20,8 +20,8 @@ ifup() fi # don't bring up an interface that's already up [ "$(/sbin/ifconfig ${1} 2>/dev/null |\ - grep -v 'inet6 addr: fe80:' |\ - grep -e 'inet addr:' -e 'inet6 addr:')" ] && return 0 + /bin/grep -v 'inet6 addr: fe80:' |\ + /bin/grep -e 'inet addr:' -e 'inet6 addr:')" ] && return 0 eval iwcfg="\$wlan_${1}" if [ "$iwcfg" != "" ]; then /usr/sbin/iwconfig $iwcfg @@ -30,8 +30,8 @@ ifup() eval ifcfg="\$${1}" if [ "$ifcfg" = "dhcp" ]; then # remove the .pid file if it exists - rm -f /var/run/dhcpcd-${1}.pid >/dev/null 2>&1 - rm -f /var/run/dhcpcd-${1}.cache >/dev/null 2>&1 + /bin/rm -f /var/run/dhcpcd-${1}.pid >/dev/null 2>&1 + /bin/rm -f /var/run/dhcpcd-${1}.cache >/dev/null 2>&1 /sbin/dhcpcd $DHCPCD_ARGS ${1} else /sbin/ifconfig $ifcfg @@ -48,7 +48,7 @@ ifdown() eval ifcfg="\$${1}" if [ "$ifcfg" = "dhcp" ]; then if [ -f /var/run/dhcpcd-${1}.pid ]; then - kill $(cat /var/run/dhcpcd-${1}.pid) + /bin/kill $(cat /var/run/dhcpcd-${1}.pid) fi fi # Always bring the interface itself down diff --git a/rc.single b/rc.single index 9c940a5..38454f6 100755 --- a/rc.single +++ b/rc.single @@ -19,7 +19,7 @@ if [ "$PREVLEVEL" = "3" -o "$PREVLEVEL" = "5" ]; then done # find any leftover daemons and shut them down if [ -d /var/run/daemons ]; then - for daemon in $(ls /var/run/daemons); do + for daemon in $(/bin/ls /var/run/daemons); do /etc/rc.d/$daemon stop done fi diff --git a/rc.sysinit b/rc.sysinit index 6c90ce9..e341d13 100755 --- a/rc.sysinit +++ b/rc.sysinit @@ -85,7 +85,7 @@ if [ -x /sbin/udevadm -a -d /sys/block ]; then stat_done else # Static /dev, our last resort - status "Using static /dev filesystem" /bin/true + status "Using static /dev filesystem" true fi # Load modules from the MODULES array defined in rc.conf @@ -123,11 +123,11 @@ fi if /bin/pidof -o %PPID /sbin/udevd >/dev/null; then #status "Loading UDev uevents" /etc/start_udev uevents stat_busy "Loading UDev uevents" - udevstart="$(date +%s%0N)" + udevstart="$(/bin/date +%s%0N)" /sbin/udevadm trigger /sbin/udevadm settle stat_done - udevend="$(date +%s%0N)" + udevend="$(/bin/date +%s%0N)" printhl " UDev uevent processing time: $((($udevend-$udevstart)/1000000))ms\n" fi @@ -150,12 +150,12 @@ if [ -e /initrd/dev/mapper/root ]; then fi # If necessary, find md devices and manually assemble RAID arrays -if [ -f /etc/mdadm.conf -a "$(grep ^ARRAY /etc/mdadm.conf 2>/dev/null)" ]; then +if [ -f /etc/mdadm.conf -a "$(/bin/grep ^ARRAY /etc/mdadm.conf 2>/dev/null)" ]; then # udev won't create these md nodes, so we do it ourselves for dev in $(/bin/grep ^ARRAY /etc/mdadm.conf | /bin/awk '{print $2}'); do - path=$(echo $dev | sed 's|/[^/]*$||') - node=$(echo $dev | sed "s|^$path/||") - minor=$(echo $node | sed 's|^[^0-9]*||') + path=$(echo $dev | /bin/sed 's|/[^/]*$||') + node=$(echo $dev | /bin/sed "s|^$path/||") + minor=$(echo $node | /bin/sed 's|^[^0-9]*||') [ ! -e $path/$node ] && /bin/mknod $path/$node b 9 $minor done status "Activating RAID arrays" /sbin/mdadm --assemble --scan @@ -268,7 +268,7 @@ NETFS="nonfs,nonfs4,nosmbfs,nocifs,nocodafs,noncpfs,nosysfs,nousbfs,noshfs,nofus if [ -x /sbin/fsck ]; then stat_busy "Checking Filesystems" - if grep -qw quiet /proc/cmdline; then + if /bin/grep -qw quiet /proc/cmdline; then /sbin/fsck -A -T -C -a -t $NETFS $FORCEFSCK >/dev/null 2>&1 else /sbin/fsck -A -T -C -a -t $NETFS $FORCEFSCK 2>/dev/null @@ -392,7 +392,7 @@ if echo "$LOCALE" | /bin/grep -qi utf ; then # this code is needed not only for older kernels, # but also when user has set vt.default_utf8=0 but LOCALE is *.UTF-8. /usr/bin/kbd_mode -u - for i in $(seq 0 63); do + for i in $(/usr/bin/seq 0 63); do printf "\e%%G" > /dev/vc/${i} done # the $CONSOLE check helps us avoid this when running scripts from cron @@ -403,7 +403,7 @@ else stat_busy "Setting Consoles to legacy mode" # make non-UTF-8 consoles work on 2.6.24 and newer kernels /usr/bin/kbd_mode -a - for i in $(seq 0 63); do + for i in $(/usr/bin/seq 0 63); do printf "\e%%@" > /dev/vc/${i} done # the $CONSOLE check helps us avoid this when running scripts from cron @@ -418,7 +418,7 @@ if [ -n "$CONSOLEFONT" ]; then if [ -n "$CONSOLEMAP" ] && echo "$LOCALE" | /bin/grep -qi utf ; then CONSOLEMAP="" fi - for i in $(seq 0 63); do + for i in $(/usr/bin/seq 0 63); do if [ -n "$CONSOLEMAP" ]; then /usr/bin/setfont -m $CONSOLEMAP $CONSOLEFONT -C /dev/vc/${i} >/dev/null 2>&1 else @@ -428,7 +428,7 @@ if [ -n "$CONSOLEFONT" ]; then if [ $? -ne 0 ]; then stat_fail else - for i in $(seq 0 63); do + for i in $(/usr/bin/seq 0 63); do printf "\e(K" > /dev/vc/${i} done # the $CONSOLE check helps us avoid this when running scripts from cron -- cgit v1.2.3