Space character in rc.conf variable

Harald Servat redcrash at gmail.com
Sun Oct 31 00:48:52 UTC 2010


Wow!

It looks like the subject arised some issues which are out of my knowledge.
Right now, I can follow Doug's suggestion to change my SSID.

Thank you for all your comments.

2010/10/31 Mark Johnston <markjdb at gmail.com>

> On Sun, Oct 31, 2010 at 12:08:28AM +0200, Jilles Tjoelker wrote:
> > Array support in the shell could make this easier, but not much unless
> > the rc.conf syntax would be changed as well, like
> >   ifconfig_wlan0=(ssid "SSID WITH SPACE" dhcp)
> > but then changed some more such that "DHCP" can be used as SSID.
> >
> > Array support would add a fair bit of code to sh, and even then it will
> > remain fairly limited and clumsy. For example, an array can only be
> > returned from a function by passing the name of an existing array to
> > place the result in and using eval, extending setvar in some strange way
> > or implementing another ksh93 extension, namerefs.
> >
> > --
> > Jilles Tjoelker
>
> Incidentally, I've actually been working on this, though it was more for
> fun than anything else - my impression is that new features for sh(1)
> are generally unwelcome because of the testing required and the
> possibility of regressions. I have some of the syntax working, e.g.
>
> $ foo[1]=one
> $ foo[2]=two
> $ foo[3]=three
> $ echo ${foo[1]} ${foo[2]} ${foo[3]}
> one two three
> $ unset foo[2]
> $ echo ${foo[1]} ${foo[2]} ${foo[3]}
> one three
>
> It was while working on the ${#arr[@]} syntax that I ran into
> bin/151720.
>
> If people are actually interested in this, I can discuss my changes in
> more detail. The actually array implementation is quite simple, around
> 200 LOC... a number of changes to var.c, parser.c and eval.c are
> necessary however.
>
> -Mark
> _______________________________________________
> freebsd-hackers at freebsd.org mailing list
> http://lists.freebsd.org/mailman/listinfo/freebsd-hackers
> To unsubscribe, send any mail to "freebsd-hackers-unsubscribe at freebsd.org"
>



-- 
_________________________________________________________________
 Fry: You can see how I lived before I met you.
 Bender: You lived before you met me?!
 Fry: Yeah, lots of people did.
 Bender: Really?!


More information about the freebsd-hackers mailing list