route: Don't leak local $opt.
This commit is contained in:
parent
9d810be86b
commit
3998a70dd9
@ -78,7 +78,7 @@ _route()
|
|||||||
fi
|
fi
|
||||||
|
|
||||||
# Remove already given options from completions
|
# Remove already given options from completions
|
||||||
local i found
|
local opt found i
|
||||||
for opt in add del -host -net netmask metric mss window irtt reject mod \
|
for opt in add del -host -net netmask metric mss window irtt reject mod \
|
||||||
dyn reinstate dev default gw; do
|
dyn reinstate dev default gw; do
|
||||||
found=false
|
found=false
|
||||||
|
1
test/completion/route.exp
Normal file
1
test/completion/route.exp
Normal file
@ -0,0 +1 @@
|
|||||||
|
assert_source_completions route
|
20
test/lib/completions/route.exp
Normal file
20
test/lib/completions/route.exp
Normal file
@ -0,0 +1,20 @@
|
|||||||
|
proc setup {} {
|
||||||
|
save_env
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
proc teardown {} {
|
||||||
|
assert_env_unmodified
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
setup
|
||||||
|
|
||||||
|
|
||||||
|
assert_complete_any "route "
|
||||||
|
|
||||||
|
|
||||||
|
sync_after_int
|
||||||
|
|
||||||
|
|
||||||
|
teardown
|
Loading…
x
Reference in New Issue
Block a user