Rejecting device names which are not a single word
This commit is contained in:
parent
7fa1f82ed9
commit
f419f51f1e
@ -212,9 +212,16 @@ arg_interpreter() {
|
|||||||
exit 0
|
exit 0
|
||||||
elif echo "$i" | grep -v '^-' >/dev/null
|
elif echo "$i" | grep -v '^-' >/dev/null
|
||||||
then
|
then
|
||||||
devs_named=y
|
num=$(echo "$i" | wc -w)
|
||||||
devs="$devs $i"
|
if test "$num" = 1
|
||||||
show_reasons=y
|
then
|
||||||
|
devs_named=y
|
||||||
|
devs="$devs $i"
|
||||||
|
show_reasons=y
|
||||||
|
else
|
||||||
|
echo "$0 : Given device name is not a single word: '$i'" >&2
|
||||||
|
exit 12
|
||||||
|
fi
|
||||||
else
|
else
|
||||||
echo "$0 : Unknown option: $i" >&2
|
echo "$0 : Unknown option: $i" >&2
|
||||||
echo >&2
|
echo >&2
|
||||||
|
Loading…
Reference in New Issue
Block a user