[SSSD] [PATCH]Don't clean up groups for which a user has it as primary GID

Stephen Gallagher sgallagh at redhat.com
Wed Nov 3 12:30:15 UTC 2010


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

On 11/03/2010 08:23 AM, Simo Sorce wrote:
> On Wed, 03 Nov 2010 07:45:24 -0400
> Stephen Gallagher <sgallagh at redhat.com> wrote:
> 
>> +         */
>> +        subfilter = talloc_asprintf(tmpctx, "(|(%s=%s)(%s=%u))",
>> +                                    SYSDB_MEMBEROF, dn,
>> +                                    SYSDB_GIDNUM, gid);
>>          if (!subfilter) {
> 
> NACK, change the filter to use %lu and cast gid to (long unsigned) and
> then it is an ack. Although currently an id is an unsigned 32bit
> integere it is better to play safe here and do an explicit cast to a
> type know to snprintf and big enough to contain the value.

Good catch, thanks.

New patch attached.

- -- 
Stephen Gallagher
RHCE 804006346421761

Delivering value year after year.
Red Hat ranks #1 in value among software vendors.
http://www.redhat.com/promo/vendor/
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.10 (GNU/Linux)
Comment: Using GnuPG with Fedora - http://enigmail.mozdev.org/

iEYEARECAAYFAkzRVdcACgkQeiVVYja6o6PSkQCfZMQkH8z/EfADTqr6CqbvUZC4
fFAAoJunHcHiAE58qqtspMH5XHyz/QRF
=AAt1
-----END PGP SIGNATURE-----
-------------- next part --------------
A non-text attachment was scrubbed...
Name: 0001-Don-t-clean-up-groups-for-which-a-user-has-it-as-pri.patch
Type: text/x-patch
Size: 2180 bytes
Desc: not available
URL: <https://lists.fedorahosted.org/pipermail/sssd-devel/attachments/20101103/eb493b1a/attachment.bin>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: 0001-Don-t-clean-up-groups-for-which-a-user-has-it-as-pri.patch.sig
Type: application/pgp-signature
Size: 72 bytes
Desc: not available
URL: <https://lists.fedorahosted.org/pipermail/sssd-devel/attachments/20101103/eb493b1a/attachment.sig>


More information about the sssd-devel mailing list