[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [PATCH v4] daemon: Set ownership of kept build directories to the ca
From: |
John Darrington |
Subject: |
Re: [PATCH v4] daemon: Set ownership of kept build directories to the calling user. |
Date: |
Fri, 23 Dec 2016 14:33:31 +0100 |
User-agent: |
Mutt/1.5.23 (2014-03-12) |
On Fri, Dec 23, 2016 at 12:18:11PM +0100, Vincent Legoll wrote:
Hello,
+ // Change the ownership if clientUid is set. Never change the
+ // ownership or the group to "root" for security reasons.
+ if (settings.clientUid != (uid_t) -1 && settings.clientUid !=
0) {
Is "0" a magical value that don't need casting or am I missing something ?
Presumably clientUid is an unsigned integral type. Hence -1 does need a cast,
whereas
0 does not.
J'
--
Avoid eavesdropping. Send strong encrypted email.
PGP Public key ID: 1024D/2DE827B3
fingerprint = 8797 A26D 0854 2EAB 0285 A290 8A67 719C 2DE8 27B3
See http://sks-keyservers.net or any PGP keyserver for public key.
signature.asc
Description: Digital signature