projects
/
grml-network.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
f5c2c78
)
grml-vnet: add help message on missing device name
author
Michael Gebetsroither
<michael@mgeb.org>
Wed, 10 Feb 2010 17:47:35 +0000
(18:47 +0100)
committer
Michael Gebetsroither
<michael@mgeb.org>
Wed, 10 Feb 2010 17:47:35 +0000
(18:47 +0100)
sbin/grml-vnet
patch
|
blob
|
history
diff --git
a/sbin/grml-vnet
b/sbin/grml-vnet
index
97e4901
..
82aca72
100755
(executable)
--- a/
sbin/grml-vnet
+++ b/
sbin/grml-vnet
@@
-93,6
+93,12
@@
while getopts "du:g:b:ah" opt; do
done
shift $(($OPTIND - 1))
+if [[ $# < 1 ]]; then
+ echo "Error: Please give at least one device" >&2
+ printUsage
+ exit 1
+fi
+
if [[ $OPT_DEL_ == 'false' ]]; then
if [[ $OPT_BRIDGE_ != '' && $OPT_AUTO_ == 'true' ]]; then
brctl showmacs "$OPT_BRIDGE_" &>/dev/null || brctl addbr "$OPT_BRIDGE_"