зеркало из https://github.com/mozilla/gecko-dev.git
don't check for SHGetSpecialFolderPathA in shfolder.dll (cause it won't be there) and load the 'ansi' proc name from shell32.dll, bug 204246, r+sr=dougt, a=asa
This commit is contained in:
Родитель
1df4c907ed
Коммит
cf01c9d921
|
@ -110,26 +110,13 @@ NS_COM void StartupSpecialSystemDirectory()
|
|||
startup. Replacing these older calls with a single call to SHGetSpecialFolderPath
|
||||
effectively removes these calls from the performace radar. We need to
|
||||
support the older way of file location lookup on systems that do not have
|
||||
IE4.
|
||||
IE4. (Note: gets the ansi version: SHGetSpecialFolderPathA).
|
||||
*/
|
||||
gShell32DLLInst = LoadLibrary("shfolder.dll");
|
||||
gShell32DLLInst = LoadLibrary("Shell32.dll");
|
||||
if(gShell32DLLInst)
|
||||
{
|
||||
gGetSpecialPathProc = (GetSpecialPathProc) GetProcAddress(gShell32DLLInst,
|
||||
"SHGetSpecialFolderPath");
|
||||
}
|
||||
|
||||
if (!gGetSpecialPathProc)
|
||||
{
|
||||
if (gShell32DLLInst)
|
||||
FreeLibrary(gShell32DLLInst);
|
||||
|
||||
gShell32DLLInst = LoadLibrary("Shell32.dll");
|
||||
if(gShell32DLLInst)
|
||||
{
|
||||
gGetSpecialPathProc = (GetSpecialPathProc) GetProcAddress(gShell32DLLInst,
|
||||
"SHGetSpecialFolderPath");
|
||||
}
|
||||
"SHGetSpecialFolderPathA");
|
||||
}
|
||||
#endif
|
||||
}
|
||||
|
|
|
@ -133,26 +133,13 @@ NS_COM void StartupSpecialSystemDirectory()
|
|||
startup. Replacing these older calls with a single call to SHGetSpecialFolderPath
|
||||
effectively removes these calls from the performace radar. We need to
|
||||
support the older way of file location lookup on systems that do not have
|
||||
IE4.
|
||||
IE4. (Note: gets the ansi version: SHGetSpecialFolderPathA).
|
||||
*/
|
||||
gShell32DLLInst = LoadLibrary("shfolder.dll");
|
||||
gShell32DLLInst = LoadLibrary("Shell32.dll");
|
||||
if(gShell32DLLInst)
|
||||
{
|
||||
gGetSpecialPathProc = (GetSpecialPathProc) GetProcAddress(gShell32DLLInst,
|
||||
"SHGetSpecialFolderPath");
|
||||
}
|
||||
|
||||
if (!gGetSpecialPathProc)
|
||||
{
|
||||
if (gShell32DLLInst)
|
||||
FreeLibrary(gShell32DLLInst);
|
||||
|
||||
gShell32DLLInst = LoadLibrary("Shell32.dll");
|
||||
if(gShell32DLLInst)
|
||||
{
|
||||
gGetSpecialPathProc = (GetSpecialPathProc) GetProcAddress(gShell32DLLInst,
|
||||
"SHGetSpecialFolderPath");
|
||||
}
|
||||
"SHGetSpecialFolderPathA");
|
||||
}
|
||||
#endif
|
||||
}
|
||||
|
|
|
@ -133,26 +133,13 @@ NS_COM void StartupSpecialSystemDirectory()
|
|||
startup. Replacing these older calls with a single call to SHGetSpecialFolderPath
|
||||
effectively removes these calls from the performace radar. We need to
|
||||
support the older way of file location lookup on systems that do not have
|
||||
IE4.
|
||||
IE4. (Note: gets the ansi version: SHGetSpecialFolderPathA).
|
||||
*/
|
||||
gShell32DLLInst = LoadLibrary("shfolder.dll");
|
||||
gShell32DLLInst = LoadLibrary("Shell32.dll");
|
||||
if(gShell32DLLInst)
|
||||
{
|
||||
gGetSpecialPathProc = (GetSpecialPathProc) GetProcAddress(gShell32DLLInst,
|
||||
"SHGetSpecialFolderPath");
|
||||
}
|
||||
|
||||
if (!gGetSpecialPathProc)
|
||||
{
|
||||
if (gShell32DLLInst)
|
||||
FreeLibrary(gShell32DLLInst);
|
||||
|
||||
gShell32DLLInst = LoadLibrary("Shell32.dll");
|
||||
if(gShell32DLLInst)
|
||||
{
|
||||
gGetSpecialPathProc = (GetSpecialPathProc) GetProcAddress(gShell32DLLInst,
|
||||
"SHGetSpecialFolderPath");
|
||||
}
|
||||
"SHGetSpecialFolderPathA");
|
||||
}
|
||||
#endif
|
||||
}
|
||||
|
|
Загрузка…
Ссылка в новой задаче