summaryrefslogtreecommitdiff
path: root/source3/libsmb/clikrb5.c
diff options
context:
space:
mode:
Diffstat (limited to 'source3/libsmb/clikrb5.c')
-rw-r--r--source3/libsmb/clikrb5.c17
1 files changed, 9 insertions, 8 deletions
diff --git a/source3/libsmb/clikrb5.c b/source3/libsmb/clikrb5.c
index c13f663381..2e07dfdb66 100644
--- a/source3/libsmb/clikrb5.c
+++ b/source3/libsmb/clikrb5.c
@@ -127,17 +127,18 @@ krb5_error_code get_kerberos_allowed_etypes(krb5_context context,
__ERROR_XX_UNKNOWN_GET_ENCTYPES_FUNCTIONS
#endif
-#if defined(HAVE_KRB5_FREE_KTYPES)
-void free_kerberos_etypes(krb5_context context, krb5_enctype *enctypes)
+ /* the following is defined as krb5_error_code to keep it from
+ being sucked into proto.h */
+krb5_error_code free_kerberos_etypes(krb5_context context,
+ krb5_enctype *enctypes)
{
- return krb5_free_ktypes(context, enctypes);
-}
+#if defined(HAVE_KRB5_FREE_KTYPES)
+ krb5_free_ktypes(context, enctypes);
#else
-void free_kerberos_etypes(krb5_context context, krb5_enctype *enctypes)
-{
- return free(enctypes);
-}
+ SAFE_FREE(enctypes);
#endif
+ return 0;
+}
#if defined(HAVE_KRB5_AUTH_CON_SETKEY) && !defined(HAVE_KRB5_AUTH_CON_SETUSERUSERKEY)
krb5_error_code krb5_auth_con_setuseruserkey(krb5_context context,