diff options
author | Andrew Bartlett <abartlet@samba.org> | 2012-01-05 11:06:28 +1100 |
---|---|---|
committer | Andrew Bartlett <abartlet@samba.org> | 2012-01-10 21:50:07 +0100 |
commit | 39b476d1c9f97b5d1fbc9b08d7a85ac0d59934f2 (patch) | |
tree | 6a4dca51c97a4c9a923d767e72420dbeb6c5577e /source3/libsmb | |
parent | fc7b34c83a2fe44b905e8af44dcb6d06154f688d (diff) | |
download | samba-39b476d1c9f97b5d1fbc9b08d7a85ac0d59934f2.tar.gz |
krb5: Require krb5_get_init_creds_opt_alloc/free for build with krb5
This also assumes the modern API with a krb5_context argument.
Andrew Bartlett
Diffstat (limited to 'source3/libsmb')
-rw-r--r-- | source3/libsmb/clikrb5.c | 29 |
1 files changed, 0 insertions, 29 deletions
diff --git a/source3/libsmb/clikrb5.c b/source3/libsmb/clikrb5.c index 76681198b49..adb9c9c6fb1 100644 --- a/source3/libsmb/clikrb5.c +++ b/source3/libsmb/clikrb5.c @@ -1412,44 +1412,15 @@ done: krb5_error_code smb_krb5_get_init_creds_opt_alloc(krb5_context context, krb5_get_init_creds_opt **opt) { -#ifdef HAVE_KRB5_GET_INIT_CREDS_OPT_ALLOC /* Heimdal or modern MIT version */ return krb5_get_init_creds_opt_alloc(context, opt); -#else - /* Historical MIT version */ - krb5_get_init_creds_opt *my_opt; - - *opt = NULL; - - if ((my_opt = SMB_MALLOC_P(krb5_get_init_creds_opt)) == NULL) { - return ENOMEM; - } - - krb5_get_init_creds_opt_init(my_opt); - - *opt = my_opt; - return 0; -#endif /* HAVE_KRB5_GET_INIT_CREDS_OPT_ALLOC */ } void smb_krb5_get_init_creds_opt_free(krb5_context context, krb5_get_init_creds_opt *opt) { -#ifdef HAVE_KRB5_GET_INIT_CREDS_OPT_FREE - -#ifdef KRB5_CREDS_OPT_FREE_REQUIRES_CONTEXT /* Modern MIT or Heimdal version */ krb5_get_init_creds_opt_free(context, opt); -#else - /* Heimdal version */ - krb5_get_init_creds_opt_free(opt); -#endif /* KRB5_CREDS_OPT_FREE_REQUIRES_CONTEXT */ - -#else /* HAVE_KRB5_GET_INIT_CREDS_OPT_FREE */ - /* Historical MIT version */ - SAFE_FREE(opt); - opt = NULL; -#endif /* HAVE_KRB5_GET_INIT_CREDS_OPT_FREE */ } krb5_enctype smb_get_enctype_from_kt_entry(krb5_keytab_entry *kt_entry) |