[SSSD] [PATCH] sysdb: warn to syslog when removing object with same uid/gid

Pavel Březina pbrezina at redhat.com
Fri Feb 14 12:38:48 UTC 2014


On 02/14/2014 01:01 PM, Lukas Slebodnik wrote:
> On (14/02/14 12:42), Pavel Březina wrote:
>> https://fedorahosted.org/sssd/ticket/2203
>
>>From 48ede856df611eca2337b7715b018eae1c5b3b97 Mon Sep 17 00:00:00 2001
>> From: =?UTF-8?q?Pavel=20B=C5=99ezina?= <pbrezina at redhat.com>
>> Date: Fri, 14 Feb 2014 12:39:13 +0100
>> Subject: [PATCH] sysdb: warn to syslog when removing object with same uid/gid
>>
>> Resolves:
>> https://fedorahosted.org/sssd/ticket/2203
>> ---
>> src/db/sysdb_ops.c | 6 ++++++
>> 1 file changed, 6 insertions(+)
>>
>> diff --git a/src/db/sysdb_ops.c b/src/db/sysdb_ops.c
>> index 3065be6444070a8d1fceddb323cff883434eacf4..57616209b76ccc43ff2776594a61c2be44ed06d7 100644
>> --- a/src/db/sysdb_ops.c
>> +++ b/src/db/sysdb_ops.c
>> @@ -1795,6 +1795,9 @@ int sysdb_store_user(struct sss_domain_info *domain,
>>              DEBUG(SSSDBG_MINOR_FAILURE,
>>                    "A user with the same UID [%llu] was removed from the "
>>                     "cache\n", (unsigned long long) uid);
>> +            sss_log(SSS_LOG_WARNING, "A user with the same UID [%llu] was "
>> +                    "removed from the cache\n", (unsigned long long) uid);
>> +
>>              ret = sysdb_add_user(domain, name, uid, gid, gecos, homedir,
>>                                   shell, orig_dn, attrs, cache_timeout, now);
>>          }
>> @@ -1951,6 +1954,9 @@ int sysdb_store_group(struct sss_domain_info *domain,
>>              DEBUG(SSSDBG_MINOR_FAILURE,
>>                    "A group with the same GID [%llu] was removed from the "
>>                     "cache\n", (unsigned long long) gid);
>> +            sss_log(SSS_LOG_WARNING, "A group with the same GID [%llu] was "
>> +                    "removed from the cache\n", (unsigned long long) gid);
> Could you use macro SPRIuid instead of foramt string "%llu" and also remove
> explicit casting. (also in unchanged DEBUG message)
>
> Thank you
>
> LS

Done.

-------------- next part --------------
A non-text attachment was scrubbed...
Name: 0001-sysdb-warn-to-syslog-1-11.patch
Type: text/x-patch
Size: 2018 bytes
Desc: not available
URL: <https://lists.fedorahosted.org/pipermail/sssd-devel/attachments/20140214/e0851cd2/attachment.bin>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: 0001-sysdb-warn-to-syslog-master.patch
Type: text/x-patch
Size: 2004 bytes
Desc: not available
URL: <https://lists.fedorahosted.org/pipermail/sssd-devel/attachments/20140214/e0851cd2/attachment-0001.bin>


More information about the sssd-devel mailing list