HLock(thePath);
extern char* vr_findVerRegName(){    FSSpec  regSpec;    OSErr   err;    short   foundVRefNum;    long    foundDirID;    int     bCreate = 0;        /* quick exit if we have the info */    if ( verRegName != NULL )        return verRegName;    err = FindFolder(kOnSystemDisk,'pref', false, &foundVRefNum, &foundDirID);    if (!err)    {        err = FSMakeFSSpec(foundVRefNum, foundDirID, MAC_VERREG, &regSpec);        if (err == -43) /* if file doesn't exist */        {            err = FSpCreate(&regSpec, 'MOSS', 'REGS', smSystemScript);            bCreate = 1;        }        if (err == noErr)        {            Handle thePath;            short pathLen;            err = FSpGetFullPath(&regSpec, &pathLen, &thePath);            if (err == noErr && thePath)            {            #ifdef STANDALONE_REGISTRY                verRegName = XP_STRDUP(*(char**)thePath);            #else                /* Since we're now using NSPR, this HAS to be a unix path! */                const char* src;                char* dst;                verRegName = (char*)XP_ALLOC(pathLen + 2);                src = *(char**)thePath;                dst = verRegName;                *dst++ = '/';                while (pathLen--)                {                    char c = *src++;                    *dst++ = (c == ':') ? '/' : c;                }                *dst = '\0';            #endif            }            DisposeHandle(thePath);        }    }    return verRegName;}