Closed
Bug 102828
Opened 24 years ago
Closed 24 years ago
Memory leak of 58 bytes from 1 block allocated in GetWindowsFolder
Categories
(Core :: XPCOM, defect, P2)
Tracking
()
VERIFIED
DUPLICATE
of bug 103779
People
(Reporter: stephend, Assigned: tetsuroy)
Details
(Keywords: memory-leak)
Roy, CVS blames you for line 204, please re-assign as needed, thanks.
Windows 2000, debug CVS pull, fresh as of 7:30 pm 10/2/2001.
Saw this by:
* Launching mozilla.exe -mail with 1 POP3 server, with 2 new messages.
* Login at startup and saved password selected.
* Didn't actually read mail, just let biff notify me of new messages.
(Meaning, no message was _ever_ loaded, except for the subject line).
*Exited program.
[W] MLK: Memory leak of 58 bytes from 1 block allocated in GetWindowsFolder
Distribution of leaked blocks
Allocation location
strdup+0xc [strdup.c:42 ip=0x003590cc]
GetWindowsFolder+0x1d5
[c:\moz_src\mozilla\xpcom\io\nsSpecialSystemDirectory.cpp:204 ip=0x100d5845]
pBuffer[len + 1] = '\0';
// Assign the directory
=> outDirectory =strdup(pBuffer);
Clean:
// Clean up.
nsSpecialSystemDirectory::=(SystemDirectories::nsSpecialSystemDirectory)
+0xfcb [c:\moz_src\mozilla\xpcom\io\nsSpecialSystemDirectory.cpp:820
ip=0x100d4e8b]
}
case Win_Appdata:
{
=> GetWindowsFolder(CSIDL_APPDATA, *this);
break;
}
case Win_Printhood:
nsSpecialSystemDirectory::nsSpecialSystemDirectory
(SystemDirectories::nsSpecialSystemDirectory)+0x7d
[c:\moz_src\mozilla\xpcom\io\nsSpecialSystemDirectory.cpp:365 ip=0x100d3e1d]
//----------------------------------------------------------------------
------------------
: nsFileSpec(nsnull)
{
=> *this = aSystemSystemDirectory;
}
//----------------------------------------------------------------------
------------------
nsDirectoryService::GetFile(char const*,int *,nsIFile * *)+0x1fd7
[c:\moz_src\mozilla\xpcom\io\nsDirectoryService.cpp:965 ip=0x100bac57]
}
else if (inAtom == nsDirectoryService::sAppdata)
{
=> nsSpecialSystemDirectory fileSpec
(nsSpecialSystemDirectory::Win_Appdata);
rv = NS_FileSpecToIFile(&fileSpec, getter_AddRefs(localFile));
}
else if (inAtom == nsDirectoryService::sPrinthood)
FindProviderFile+0x167
[c:\moz_src\mozilla\xpcom\io\nsDirectoryService.cpp:584 ip=0x100b8337]
return PR_FALSE;
FileData* fileData = (FileData*)aData;
=> rv = prov->GetFile(fileData->property, &fileData->persistent, &
(fileData->file) );
if (NS_SUCCEEDED(rv) && fileData->file)
return PR_FALSE;
nsDirectoryService::Get(char const*,nsID const&,void * *)+0x5c0
[c:\moz_src\mozilla\xpcom\io\nsDirectoryService.cpp:628 ip=0x100b8020]
return rv;
}
=> FindProviderFile(NS_STATIC_CAST(nsIDirectoryServiceProvider*,
this), &fileData);
if (fileData.file)
{
if (fileData.persistent)
nsAppFileLocationProvider::GetProductDirectory(nsILocalFile * *)+0x262
[c:\moz_src\mozilla\xpcom\io\nsAppFileLocationProvider.cpp:273 ip=0x100dbfe2]
nsCOMPtr<nsIProperties> directoryService =
do_GetService(NS_DIRECTORY_SERVICE_CONTRACTID, &rv);
if (NS_FAILED(rv)) return rv;
=> rv = directoryService->Get(NS_WIN_APPDATA_DIR, NS_GET_IID
(nsILocalFile), getter_AddRefs(localDir));
if (NS_SUCCEEDED(rv))
rv = localDir->Exists(&exists);
if (NS_FAILED(rv) || !exists)
nsAppFileLocationProvider::GetFile(char const*,int *,nsIFile * *)+0x1d9
[c:\moz_src\mozilla\xpcom\io\nsAppFileLocationProvider.cpp:134 ip=0x100da9e7]
}
else if (nsCRT::strcmp(prop, NS_APP_APPLICATION_REGISTRY_FILE) == 0)
{
=> rv = GetProductDirectory(getter_AddRefs(localFile));
if (NS_SUCCEEDED(rv))
rv = localFile->Append(APP_REGISTRY_NAME);
}
FindProviderFile+0x167
[c:\moz_src\mozilla\xpcom\io\nsDirectoryService.cpp:584 ip=0x100b8337]
return PR_FALSE;
FileData* fileData = (FileData*)aData;
=> rv = prov->GetFile(fileData->property, &fileData->persistent, &
(fileData->file) );
if (NS_SUCCEEDED(rv) && fileData->file)
return PR_FALSE;
| Reporter | ||
Updated•24 years ago
|
| Assignee | ||
Updated•24 years ago
|
Status: NEW → ASSIGNED
Comment 2•24 years ago
|
||
dup
*** This bug has been marked as a duplicate of 103779 ***
Status: ASSIGNED → RESOLVED
Closed: 24 years ago
Resolution: --- → DUPLICATE
You need to log in
before you can comment on or make changes to this bug.
Description
•