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

List:       kde-core-devel
Subject:    Re: signal signatures vs. inheritance (Re: [PATCH] KProcess port
From:       Oswald Buddenhagen <ossi () kde ! org>
Date:       2007-12-20 22:20:49
Message-ID: 20071220222049.GA11115 () ugly ! local
[Download RAW message or body]

On Thu, Dec 20, 2007 at 10:44:33PM +0100, Ralf Habacker wrote:
> Oswald Buddenhagen schrieb:
>> On Thu, Dec 20, 2007 at 08:14:16PM +0100, Ralf Habacker wrote:
>>>    meinproc->setOutputChannelMode(KProcess::SeparateChannels);
>>>
>> OnlyStdoutChannel, but anyway ...
>>   
> really ? in toc.cpp for example the stderr channel is printed with kDebug, 
> stdout is ignored
>
request only channels that you
- actually want to handle or
- positively and definitely what to trash (*)
anything else is lost potentially useful debug information.

(*) if you trash a channel, use closeReadChannel() to avoid filling up
the memory. (**)
(**) actually, redirecting to the null device would be better. (***)
(***) hmm, i think i should add KProcess::NullDevice (****) which
expands to /dev/null resp. NUL.
(****) alternative names: KProcess::BitBucket, KProcess::Nirvana,
... :) (*****)
(*****) recursive footnotes rox0r :=)

> is is compilable because KProcess inherits QProcess and  ExitStatus type is 
> visible in KProcess :-(
>
that's a feature, not a bug. ;)
only qt screws up at some variation(s) of this.

> could this not supressed to avoid that this is compilable like done
> with    
> class KProcess
> <snip>
> // hide those
>    using QProcess::setReadChannelMode;
>
that's actually a good idea ... but only for this one function (and the
respective getter). :)

-- 
Hi! I'm a .signature virus! Copy me into your ~/.signature, please!
--
Confusion, chaos, panic - my work here is done.
[prev in list] [next in list] [prev in thread] [next in thread] 

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