[prev in list] [next in list] [prev in thread] [next in thread] 

List:       kde-commits
Subject:    Re: quanta [POSSIBLY UNSAFE]
From:       Mantia Andras <amantia () freemail ! hu>
Date:       2002-12-08 10:35:56
[Download RAW message or body]

On 2002. December 08., Sunday 12:11, Waldo Bastian wrote:
> On Sunday 08 December 2002 11:01, Andras Mantia wrote:
> >    QString args = arguments();
> > +  if (!args.isEmpty())
> > +     args = KProcess::quote(args);
>
> Are you sure that is correct? The name suggests that you can have multiple
> arguments (like what?) but if you quote them they will be interpreted as a
> single argument.
>
> Cheers,
> Waldo

Yes, you are right, and it breaks when you specify multiple arguments, but it 
does not always work even with one argument! KProcess::quote("~/dir/foo") 
returns  '~/dir/foo', which is not good for apps. I've tried it with kompare 
and cat.

andris@stein:~/cvs-developement/head/quanta> cat '~/.kderc'
cat: ~/.kderc: No such file or directory

Is this the desired behaviour of KProcess:quote()?

Otherwise thank you for pointing out, I've never tried the plugin system with 
arguments (as I'm not the author of this code)...

Andras
[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic