On Montag, 2. Juli 2007, Thorsten Glaser wrote:
> Dirk Nehring dixit:
> >That's one reason why "set -u" helps
>
> I still don't care. Besides, this was a no-op, since ifacelist wasn't used
> in that function. (Otherwise I had bumped the dashver.)
>
> //mirabile
No, you both are wrong.
See the following:
funct1() {
local ifacelist
funct2
funct3
}
funct2() {
# fill ifacelist
ifacelist="foo bar"
}
funct3() {
# use ifacelist
for var in $ifacelist; do
echo $var
done
}
If you do so ifacelist is valid for all three functions but NOT for the
calling script or a calling function.
And that is what I want.
Bye
Christian
--
"Without music to decorate it, time is just a bunch of boring production
deadlines or dates by which bills must be paid."
--- Frank Vincent Zappa
_______________________________________________
freewrt-developers mailing list
[email protected]
https://www.freewrt.org/lists/listinfo/freewrt-developers