Mac specific fix. Checking in rjc's fix to load libraries if file spec was an alias to a library rather than the actual library file spec. Needed so XPCOM will work on Mac.

This commit is contained in:
sdagley%netscape.com 1999-02-18 00:10:46 +00:00
Родитель d3f3cfce1d
Коммит d59873884c
1 изменённых файлов: 7 добавлений и 0 удалений

Просмотреть файл

@ -596,6 +596,8 @@ PR_LoadLibrary(const char *name)
FSSpec fileSpec;
PRUint32 index;
Boolean tempUnusedBool; // rjc
/* Copy the name: we'll change it */
cMacPath = strdup(name);
if (cMacPath == NULL)
@ -646,6 +648,11 @@ PR_LoadLibrary(const char *name)
goto unlock;
fileSpec.parID = pb.dirInfo.ioDrDirID;
// resolve an alias if this was one (rjc)
err = ResolveAliasFile(&fileSpec, true, &tempUnusedBool, &tempUnusedBool);
if (err != noErr)
goto unlock;
/* Finally, try to load the library */
err = GetDiskFragment(&fileSpec, 0, kCFragGoesToEOF, fileSpec.name,
kLoadCFrag, &connectionID, &main, errName);