Bug 1409275 - Default to gssapi64 on 64-bit windows
MozReview-Commit-ID: 4Y1RmMwsHPN
--- a/extensions/auth/nsAuthGSSAPI.cpp
+++ b/extensions/auth/nsAuthGSSAPI.cpp
@@ -113,19 +113,25 @@ gssInit()
if (!libPath.IsEmpty()) {
LOG(("Attempting to load user specified library [%s]\n", libPath.get()));
gssNativeImp = false;
lib = PR_LoadLibrary(libPath.get());
}
else {
#ifdef XP_WIN
- char *libName = PR_GetLibraryName(nullptr, "gssapi32");
+ #ifdef _WIN64
+ static const char *kLibName = "gssapi64";
+ #else
+ static const char *kLibName = "gssapi32";
+ #endif
+
+ char *libName = PR_GetLibraryName(nullptr, kLibName);
if (libName) {
- lib = PR_LoadLibrary("gssapi32");
+ lib = PR_LoadLibrary(kLibName);
PR_FreeLibraryName(libName);
}
#elif defined(__OpenBSD__)
/* OpenBSD doesn't register inter-library dependencies in basesystem
* libs therefor we need to load all the libraries gssapi depends on,
* in the correct order and with LD_GLOBAL for GSSAPI auth to work
* fine.
*/