diff --git a/lib/krb5_wrap/krb5_samba.c b/lib/krb5_wrap/krb5_samba.c index 6f9ae4d822b..a1884853c61 100644 --- a/lib/krb5_wrap/krb5_samba.c +++ b/lib/krb5_wrap/krb5_samba.c @@ -126,21 +126,6 @@ void krb5_free_string(krb5_context context, char *val) { } #endif -#if defined(HAVE_KRB5_PRINCIPAL_GET_COMP_STRING) && !defined(HAVE_KRB5_PRINC_COMPONENT) -const krb5_data *krb5_princ_component(krb5_context context, - krb5_principal principal, int i); - -const krb5_data *krb5_princ_component(krb5_context context, - krb5_principal principal, int i) -{ - static krb5_data kdata; - - kdata.data = discard_const_p(char, krb5_principal_get_comp_string(context, principal, i)); - kdata.length = strlen((const char *)kdata.data); - return &kdata; -} -#endif - krb5_error_code smb_krb5_princ_component(krb5_context context, krb5_const_principal principal, int i, diff --git a/source4/auth/kerberos/kerberos.h b/source4/auth/kerberos/kerberos.h index 41c9b048aaf..5b13f567a00 100644 --- a/source4/auth/kerberos/kerberos.h +++ b/source4/auth/kerberos/kerberos.h @@ -61,10 +61,6 @@ krb5_error_code krb5_set_default_tgs_ktypes(krb5_context ctx, const krb5_enctype krb5_error_code krb5_auth_con_setuseruserkey(krb5_context context, krb5_auth_context auth_context, krb5_keyblock *keyblock); #endif -#if defined(HAVE_KRB5_PRINCIPAL_GET_COMP_STRING) && !defined(HAVE_KRB5_PRINC_COMPONENT) -const krb5_data *krb5_princ_component(krb5_context context, krb5_principal principal, int i ); -#endif - krb5_error_code smb_krb5_princ_component(krb5_context context, krb5_const_principal principal, int i,