[PATCHv2] cifs-utils: work around missing krb5_free_string in Heimdal

Jeremy Allison jra at samba.org
Fri Mar 4 22:57:38 UTC 2022

On Sat, Mar 05, 2022 at 12:51:43AM +0200, atheik wrote:
>On 3/4/22, Jeremy Allison <jra at samba.org> wrote:
>> Does cifs-utils have a libreplace equivalent ?
>I have no idea about libreplace but cifs.upcall.c of
>cifs-utils already has a lot of these #ifdefs for
>compatibility between MIT and Heimdal KRB5.
>> Wouldn't it be easier to test for the existence of
>> krb5_free_string() and write a libreplace wrapper
>> function so krb5_free_string() can be called from
>> all code without #ifdefs in the main code ?
>This patch adds just another #ifdef to cifs.upcall.c
>so that cifs-utils builds against Heimdal again.
>I have attached a new patch that doesn't place the
>#ifdefs in the function body.

That looks cleaner to me, thanks !

More information about the samba-technical mailing list