Christoph Simon wrote:

> Someone already stated that the space is a token separator (in many
> computer related contexts, not just limited to unix like OSs, but
> including MS-Windows). Also, if you find your for-loop
> counter-intuitive, you are demonstrating to use variables without
> bearing in mind their meaning. If you find `counter-intuitive' that a
> space is a token separator, why did you use it between the tokens?
> shouldn't you suggest another character instead?

You totally missed the point. The space was in a quoted string. The Unix
shells understand quoted strings, but the quotes are lost when such strings
are assigned to variables, so when the variable is expanded, the quoted
string becomes multiple strings. Which is a useful ability to have, but
it shouldn't be the default.

I am not "demonstrating to use variables without bearing in mind their
meaning". I am demonstrating a semantic irregularity in the functioning
of the common Unix shells, and I have already mentioned that there are a
number of well-known problems, including breakage of filenames with
spaces, but ALSO including security compromises resulting from the
expansion of variables whose values were read from user input (e.g. in
cgi scripts) which trace DIRECTLY to this semantic irregularity.

I hope this point is clear now.

> Unfortunately people like those from StarOffice, Gnome, etc. think
> like you, that typing commands is anacronic.

I've said nothing to suggest any such thing. I like command lines. That
you think I've said otherwise speaks very poorly for your reading
comprehension skills.

Craig

Reply via email to