knod of the head to sfraser, for reminding me that you need to also initialize processInfoRec with the size of the process record.

This commit is contained in:
cyeh%netscape.com 1999-03-02 00:34:49 +00:00
parent 9fee508b26
commit d9f55cbdaf
2 changed files with 2 additions and 0 deletions

View File

@ -1490,6 +1490,7 @@ nsresult nsRepository::AutoRegister(NSRegistrationInstant when,
// initialize ProcessInfoRec before calling GetProcessInformation() or die horribly.
pInfo.processName = nil;
pInfo.processAppSpec = &tempSpec;
pInfo.processInfoLength = sizeof(ProcessInfoRec);
if (!(err = GetProcessInformation(&psn, &pInfo)))
{
appFSSpec = *(pInfo.processAppSpec);

View File

@ -1490,6 +1490,7 @@ nsresult nsRepository::AutoRegister(NSRegistrationInstant when,
// initialize ProcessInfoRec before calling GetProcessInformation() or die horribly.
pInfo.processName = nil;
pInfo.processAppSpec = &tempSpec;
pInfo.processInfoLength = sizeof(ProcessInfoRec);
if (!(err = GetProcessInformation(&psn, &pInfo)))
{
appFSSpec = *(pInfo.processAppSpec);