[Os-project-managers] Ticket 50

Horand Gassmann Horand.Gassmann at Dal.Ca
Wed May 2 06:09:38 EDT 2012


Horand Gassmann <Horand.Gassmann at dal.ca> wrote:

> "R. Kipp Martin" <kmartin at chicagobooth.edu> wrote:
>
>>> The other point is that Mike talked about folder names, not file names,
>>> and there the user actually may not have a lot of choice. Under Windows,
>>> for instance, it is quite common to have one's files stored under the
>>> "My Documents" folder, which is generated by the system. I think it is a
>>> bit much to ask the user to change the name or use a different location
>>> just so that OSAmplClient can stay "pure". No offense, but I definitely
>>> think you are misguided on this one.
>>
>> They can move the files. Even idiotic Windows lets you move files!!!!!
>
> I had another look at Mike Steglich's code and remarks. I noticed  
> two things. First, his remark about the command line shell  
> (explained by Stefan in a later email) is true. Even if you put  
> double quotes around a command line argument, the quotes get  
> stripped before the string is put into argV.
>
> Second, however, was the pattern I discovered in OSParseosss.l:
>
> optionValue ([-a-zA-Z./~:_0-9$\?+\\!@#&*()]+|\"[^"\n]*\")
>
> The second part of this pattern explicitly looks for strings  
> enclosed in double quotes, so it seems we are already catering for  
> this possibility.
>
> If you put a command line argument (any argument) into double quotes  
> --- which is legal ---, you are clearly signalling that this  
> argument should be handled as one argument, even if it contains  
> spaces, but our system splits it apart. So I am thinking that this  
> is a bug in OSSolverService.cpp.

To follow up my own message, here is how I think we should fix ticket 50:

In the loop at lines 228-235 (OSSolverService.cpp) we should add a  
test whether argV[i] contains a blank. If it does, we need to add  
quotes around it when we do the concatenation. The parser will then do  
the expected, and everything will be fine.

Comments?

Cheers

gus



More information about the Os-project-managers mailing list