summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMike Frysinger <vapier@gentoo.org>2006-08-20 04:23:10 +0000
committerMike Frysinger <vapier@gentoo.org>2006-08-20 04:23:10 +0000
commit4db83d1e0a3597bffb82290c093c9dedf276b82d (patch)
tree4bfe8fdd18abc9660234a4b426bc48ef9d285225 /sys-apps/hdparm/files
parentspruce up the init.d and default config files (diff)
downloadgentoo-2-4db83d1e0a3597bffb82290c093c9dedf276b82d.tar.gz
gentoo-2-4db83d1e0a3597bffb82290c093c9dedf276b82d.tar.bz2
gentoo-2-4db83d1e0a3597bffb82290c093c9dedf276b82d.zip
really fix default arg check #142777
(Portage version: 2.1.1_pre5-r2)
Diffstat (limited to 'sys-apps/hdparm/files')
-rw-r--r--sys-apps/hdparm/files/hdparm-init-76
1 files changed, 4 insertions, 2 deletions
diff --git a/sys-apps/hdparm/files/hdparm-init-7 b/sys-apps/hdparm/files/hdparm-init-7
index 2b0701ae5fe9..7f43dfd5098e 100644
--- a/sys-apps/hdparm/files/hdparm-init-7
+++ b/sys-apps/hdparm/files/hdparm-init-7
@@ -25,8 +25,10 @@ depend() {
}
do_hdparm() {
- local my_all_args="${all_args} ${!extra_args}"
- if [[ -n ${args:=${my_all_args}} ]] ; then
+ if [[ -z ${args}${all_args}${!extra_args} ]] ; then
+ return 0
+ fi
+ if [[ -n ${args:=${all_args} ${!extra_args}} ]] ; then
local orgdevice=$(readlink -f ${device})
if [[ -b ${orgdevice} ]] ; then
ebegin "Running hdparm on ${device}"