From: Tom Yu Date: Mon, 1 Oct 2007 23:13:45 +0000 (+0000) Subject: pull up r19977 from trunk X-Git-Tag: krb5-1.6.3-beta2~38 X-Git-Url: http://git.tremily.us/?a=commitdiff_plain;h=4569622dc0323b66561758226572cd374efb32de;p=krb5.git pull up r19977 from trunk r19977@cathode-dark-space: jaltman | 2007-09-25 00:19:52 -0400 ticket: 5772 change all MAX_PATH ccname buffer lengths to KRB5_CCH_CCNAME and document the use of KRB5_CCH_CCNAME. ticket: 5772 git-svn-id: svn://anonsvn.mit.edu/krb5/branches/krb5-1-6@20050 dc483132-0cff-0310-8789-dd5450dbe970 --- diff --git a/src/windows/identity/plugins/krb5/krb5funcs.c b/src/windows/identity/plugins/krb5/krb5funcs.c index 5a4120ff4..59cbe32cc 100644 --- a/src/windows/identity/plugins/krb5/krb5funcs.c +++ b/src/windows/identity/plugins/krb5/krb5funcs.c @@ -211,7 +211,7 @@ typedef struct tag_ident_data { khm_handle ident; /* handle to the identity */ khm_int32 count; /* number of initial tickets we have found for this identity. */ - wchar_t ccname[MAX_PATH]; + wchar_t ccname[KRB5_MAXCCH_CCNAME]; FILETIME ft_issue; FILETIME ft_expire; FILETIME ft_renewexpire; @@ -933,7 +933,7 @@ khm_krb5_list_tickets(krb5_context *krbv5Context) == KHM_ERROR_TOO_LONG && cb > sizeof(wchar_t) * 2) { wchar_t * t; - char ccname[MAX_PATH + 6]; + char ccname[KRB5_MAXCCH_CCNAME]; ms = PMALLOC(cb); #ifdef DEBUG @@ -1393,7 +1393,7 @@ khm_krb5_kinit(krb5_context alt_ctx, } else { khm_handle identity = NULL; wchar_t idname[KCDB_IDENT_MAXCCH_NAME]; - char ccname[MAX_PATH]; + char ccname[KRB5_MAXCCH_CCNAME]; char * pccname = principal_name; khm_size cb; @@ -2165,7 +2165,7 @@ khm_krb5_ms2mit(char * match_princ, BOOL match_realm, BOOL save_creds, krb5_principal princ = 0; khm_handle ident = NULL; wchar_t idname[KCDB_IDENT_MAXCCH_NAME]; - char ccname[MAX_PATH]; + char ccname[KRB5_MAXCCH_CCNAME]; char *cache_name = NULL; char *princ_name = NULL; BOOL rc = FALSE; @@ -3117,9 +3117,9 @@ get_default_file_cache_for_identity(const wchar_t * idname, wchar_t * ccname, khm_size * pcb) { - wchar_t escf[MAX_PATH] = L""; - wchar_t tmppath[MAX_PATH] = L""; - wchar_t tccname[MAX_PATH]; + wchar_t escf[KRB5_MAXCCH_CCNAME] = L""; + wchar_t tmppath[KRB5_MAXCCH_CCNAME] = L""; + wchar_t tccname[KRB5_MAXCCH_CCNAME]; khm_size cb; escape_string_for_filename(idname, escf, sizeof(escf)); @@ -3157,7 +3157,7 @@ khm_krb5_get_identity_default_ccache(khm_handle ident, wchar_t * buf, khm_size * /* we need to figure out the default ccache from the principal name */ wchar_t idname[KCDB_IDENT_MAXCCH_NAME]; - wchar_t ccname[MAX_PATH]; + wchar_t ccname[KRB5_MAXCCH_CCNAME]; khm_size cb; khm_int32 use_file_cache = 0;