[prev in list] [next in list] [prev in thread] [next in thread]
List: kde-core-devel
Subject: Re: [PATCH] kdesu on freebsd
From: Frerich Raabe <raabe () kde ! org>
Date: 2003-09-24 18:41:24
[Download RAW message or body]
Am Wednesday 24 September 2003 19:53 schrieb Adriaan de Groot:
> The attached patch (against kdelibs/kdesu in HEAD) tries to fix kdesu on
> FreeBSD and do a little cleanup at the same time.
Excellent!
> The solution (bits): split out some of the wait and check process code into
> separate functions. I've added them to process.h, for want of a better
> place. Since that's a public header file, this may not be a good idea, but
> doing it differently would require adding a file.
>
> kdesu should check that su: is still running when it expects it to.
In ConverseSU I saw "state == 2 ? notauthorized : error" -- I think comparing
"state" with an integer is not safe (I'm not sure but I think enums are not
guaranteed to start at zero - in any case, using an enum value is more
readable), better compare with "HandleStub" instead (which is what you meant,
I guess).
> In su.{h,cpp}, I've replaced some integer constants by enums, in order to
> create some clarity in the forest of 0,1,2,-2,-1, etc. constants being
> thrown around.
If you now replace "checkMode" with "CheckMode", and "ConverseSU" with
"converseSU", then it even fits to the KDE-wide naming scheme.
- Frerich
--
"If you fail to adjust your notion of fairness to the reality of the Universe,
you will probably not be happy." - Paratima, of http://free-dc.org fame
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic