[SSSD] [PATCH] confdb: Make offline timeout configurable

Michal Židek mzidek at redhat.com
Fri Nov 1 11:37:07 UTC 2013


On 10/31/2013 06:40 PM, Jakub Hrozek wrote:
> On Thu, Oct 31, 2013 at 12:54:04PM +0100, Michal Židek wrote:
>> On 10/27/2013 07:32 PM, Jakub Hrozek wrote:
>>> On Fri, 2013-10-25 at 20:11 -0400, Simo Sorce wrote:
>>>> On Fri, 2013-10-25 at 17:42 +0200, Michal Židek wrote:
>>>>> I decided not to only document the behaviour, but also add option to
>>>>> configure it (so I could remove one FIXME from the code).
>>>>>
>>>>> https://fedorahosted.org/sssd/ticket/1718
>>>>
>>>> Thanks a lot, glad to see a long standing FIXME go away.
>>>>
>>>> Ack,
>>>> Simo.
>>>>
>>>
>>> The code itself is good, but you also need to add the parameter to the
>>> confAPI. In particular, src/config/etc/sssd.api.conf and then make sure
>>> make check passes.
>>>
>>
>> Done.
>>
>> Michal
>>
>
> Sorry I didn't think about it the first time around, but I think the
> code should also initialize offline_timeout to the default value so that
> if confdb_get_int fails for whatever reason, we still decide based on
> the default value. Ignoring the result if confdb_get_int is fine, but we
> could warn with a DEBUG message.

Yes, sorry, I completely forgot about this, it would also add coverity 
warning, since I ignored the return value. But I think it is better to 
init the value after the confdb_get_int fails. I prefer to assume that 
output parameters of failed functions are always undefined (even if in 
this case, it would be safe to expect that the parameter value was not 
changed).

Thanks,

Michal
-------------- next part --------------
A non-text attachment was scrubbed...
Name: 0001-confdb-Make-offline-timeout-configurable.patch
Type: text/x-patch
Size: 4273 bytes
Desc: not available
URL: <https://lists.fedorahosted.org/pipermail/sssd-devel/attachments/20131101/23ecdcee/attachment.bin>


More information about the sssd-devel mailing list