tech-userlevel archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Re: shell quoting



But, for the purposes of showing how something unintended
might occur (the f 'a b' solution is easy, but not particularly
productive), consider the following version

> sh.trick
f 'sh.*'
		--> You Win!  (again)

Now consider if the code did

	set -- $foo

and instead of sh.trick (just one file that matches sh.*)
we instead did

	> 'sh.junk foo=*.c'

and imagine what code which thinks it is getting a list
of sh.* files into the numeric args, instead gets a list
of all *.c files instead.

kre


Home | Main Index | Thread Index | Old Index