From eebc929abb66b2affe407c3e1c2255f2c3e2ca28 Mon Sep 17 00:00:00 2001 From: Victor Lowther Date: Sat, 14 Aug 2010 14:23:24 -0500 Subject: [PATCH] Clean up some conditional checking when trying to find our config files. No point in checking the same condition twice when compound commands will do. --- dracut | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/dracut b/dracut index 541bfc0bc..a65398104 100755 --- a/dracut +++ b/dracut @@ -131,13 +131,13 @@ export PATH # if we were not passed a config file, try the default one if [[ ! -f $conffile ]]; then - [[ $allowlocal ]] || conffile="/etc/dracut.conf" - [[ $allowlocal ]] && conffile="$dracutbasedir/dracut.conf" + [[ $allowlocal ]] && conffile="$dracutbasedir/dracut.conf" || \ + conffile="/etc/dracut.conf" fi if [[ ! -d $confdir ]]; then - [[ $allowlocal ]] || confdir="/etc/dracut.conf.d" - [[ $allowlocal ]] && confdir="$dracutbasedir/dracut.conf.d" + [[ $allowlocal ]] && confdir="$dracutbasedir/dracut.conf.d" \ + confdir="/etc/dracut.conf.d" fi # source our config file -- 2.47.3