Latest Time Machine Patch

Omri Mor omri50 at
Sat Sep 30 00:21:46 UTC 2017

This was discussed previously. Did you read the warning I put in the top of the file?

 * Avahi aborts on allocation failure (OOM),
 * unless a custom allocator which doesn't do so has been set.
 * This is particularly important for the avahi_string_list_*() functions,
 * which return NULL on allocation failure.
 * Since it should abort on allocation failure (before returning NULL),
 * we don't check the result.

Adding in a check for NULL doesn’t matter, as it aborts long before we would see that NULL.
In fact, the documentation doesn’t even state that it /can/ return NULL—I only found that out by reading the Avahi source.


> On Sep 29, 2017, at 19:09, Jeremy Allison <jra at> wrote:
> On Wed, Sep 27, 2017 at 11:28:23AM +0200, Ralph Böhme wrote:
>> On Wed, Sep 20, 2017 at 12:20:57AM +0000, Kevin Anderson wrote:
>>> I personally agree with a warning in case a user sets strict sync to
>>> no. I have added the check and reattached the patch series. Can I have
>>> a review for these?
>> reviewed by me. Can I have a second team member review please? Thanks!
> Sorry, NAK on the avahi patch.
> +                               adisk = avahi_string_list_add_printf(
> +                                           adisk, "dk%d=adVN=%s,adVF=0x82",
> +                                           dk++, lp_const_servicename(snum));
> and
> +                       adisk = avahi_string_list_add(adisk, "sys=adVF=0x100");
> have no return NULL check for allocation fail. Add those checks
> and it looks better.
> Jeremy.

More information about the samba-technical mailing list