diff options
-rw-r--r-- | cifs.upcall.c | 8 | ||||
-rw-r--r-- | configure.ac | 5 |
2 files changed, 13 insertions, 0 deletions
diff --git a/cifs.upcall.c b/cifs.upcall.c index 7a8c374..bf4eb5d 100644 --- a/cifs.upcall.c +++ b/cifs.upcall.c @@ -190,6 +190,14 @@ static void krb5_free_unparsed_name(krb5_context context, char *val) } #endif +#if !defined(HAVE_KRB5_FREE_STRING) /* Heimdal */ +static void krb5_free_string(krb5_context context, char *val) +{ + (void)context; + krb5_xfree(val); +} +#endif + #if !defined(HAVE_KRB5_AUTH_CON_GETSENDSUBKEY) /* Heimdal */ static krb5_error_code krb5_auth_con_getsendsubkey(krb5_context context, diff --git a/configure.ac b/configure.ac index 19fb3d0..2b1aae6 100644 --- a/configure.ac +++ b/configure.ac @@ -256,6 +256,11 @@ if test $enable_cifsupcall != "no"; then AC_CHECK_FUNCS([krb5_auth_con_setaddrs krb5_auth_con_set_req_cksumtype]) fi +# determine how to free a string allocated by a krb5 function +if test $enable_cifsupcall != "no"; then + AC_CHECK_FUNCS([krb5_free_string]) +fi + if test $enable_systemd != "no"; then AC_DEFINE(ENABLE_SYSTEMD, 1, [Enable systemd specific behavior for mount.cifs]) fi |