[9fans] rc word splitting trouble

2010-04-03 Thread Ethan Grammatikidis
I'm writing a little web server in rc. For the most part it's been less trouble than setting up Apache to serve static files, but I've run into an odd little problem where rc appears to be behaving differently depending on whether it's run in a script or a terminal. (Rc 9term from p9p.)

Re: [9fans] rc word splitting trouble

2010-04-03 Thread erik quanstrom
% fullloc = '/one/two?three+four' % params = `{echo $fullloc | sed -e 's;.*\?;;' -e 's;\+; ;g'} % for(param in $params) echo 'li'$param lithree lifour The 2nd and 3rd command lines are copied directly from the script, but the script itself outputs the following:

Re: [9fans] rc word splitting trouble

2010-04-03 Thread Ethan Grammatikidis
On 3 Apr 2010, at 15:38, erik quanstrom wrote: % fullloc = '/one/two?three+four' % params = `{echo $fullloc | sed -e 's;.*\?;;' -e 's;\+; ;g'} % for(param in $params) echo ' li'$param lithree lifour The 2nd and 3rd command lines are copied directly from the script, but the