From 4d752ce458b92158b3516c02225152e8f372f815 Mon Sep 17 00:00:00 2001 From: Tom Yu Date: Sat, 29 Sep 2007 00:09:54 +0000 Subject: [PATCH] pull up r19929 from trunk r19929@cathode-dark-space: jaltman | 2007-09-05 18:48:06 -0400 ticket:new subject: 64-bit Windows krb5int_cc_default calls to Leash AMD64 builds must load leashw64.dll not leashw32.dll ticket: 5713 version_fixed: 1.6.3 git-svn-id: svn://anonsvn.mit.edu/krb5/branches/krb5-1-6@20013 dc483132-0cff-0310-8789-dd5450dbe970 --- src/lib/krb5/ccache/ccdefault.c | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/src/lib/krb5/ccache/ccdefault.c b/src/lib/krb5/ccache/ccdefault.c index 3c363229a..d36b10474 100644 --- a/src/lib/krb5/ccache/ccdefault.c +++ b/src/lib/krb5/ccache/ccdefault.c @@ -34,6 +34,11 @@ #elif defined(USE_LEASH) static void (*pLeash_AcquireInitialTicketsIfNeeded)(krb5_context,krb5_principal,char*,int) = NULL; static HANDLE hLeashDLL = INVALID_HANDLE_VALUE; +#ifdef _WIN64 +#define LEASH_DLL "leashw64.dll" +#else +#define LEASH_DLL "leashw32.dll" +#endif #endif @@ -86,7 +91,7 @@ krb5int_cc_default(krb5_context context, krb5_ccache *ccache) #else #ifdef USE_LEASH if ( hLeashDLL == INVALID_HANDLE_VALUE ) { - hLeashDLL = LoadLibrary("leashw32.dll"); + hLeashDLL = LoadLibrary(LEASH_DLL); if ( hLeashDLL != INVALID_HANDLE_VALUE ) { (FARPROC) pLeash_AcquireInitialTicketsIfNeeded = GetProcAddress(hLeashDLL, "not_an_API_Leash_AcquireInitialTicketsIfNeeded"); -- 2.26.2