diff options
author | maximilian attems <maks@debian.org> | 2009-04-03 14:48:44 +0200 |
---|---|---|
committer | maximilian attems <maks@debian.org> | 2009-04-03 14:52:20 +0200 |
commit | d703b8ca26ac5230d7ffeae1891334791d8dab31 (patch) | |
tree | e16d11c8d6291b789269d510629e09108973296e /scripts/functions | |
parent | e939f98f684326ddc06d54fe0379c552fb94010f (diff) |
cleanup LABEL handling code
make it more concise:
* use POSIX ${parameter:+word}
* replace *[/]*) by just */*)
* test exit code of command -v rather then running test -x on it
while we are at it fix another command -v usage in scripts/functions.
Reviewed-by: Colin Watson <cjwatson@ubuntu.com>
Signed-off-by: maximilian attems <maks@debian.org>
Diffstat (limited to 'scripts/functions')
-rw-r--r-- | scripts/functions | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/scripts/functions b/scripts/functions index b813529..77de8f3 100644 --- a/scripts/functions +++ b/scripts/functions @@ -304,6 +304,6 @@ configure_networking() # Wait for queued kernel/udev events wait_for_udev() { - [ -x "$(command -v udevadm)" ] || return 0 + command -v udevadm >/dev/null 2>&1 || return 0 udevadm settle ${1:+--timeout=$1} } |