Closed
Bug 32607
Opened 24 years ago
Closed 24 years ago
MLK: Leaking nsCachedNetData objects.
Categories
(Core :: Networking: Cache, defect, P3)
Core
Networking: Cache
Tracking
()
M17
People
(Reporter: bruce, Assigned: gordon)
Details
Visible when loading http://www.wired.com/ at least. Don't know about other cases yet. I fixed one large leak through here of the string itself in nsCachedNetData::Deserialize(), so I don't think this is that again. Maybe we're leaking nsCachedNetData objects? According to bloaty: 128 nsCachedNetData 68 1224 18 18 ( 9.50 +/- 5.34) 205 18 ( 30.42 +/- 13.06) We leak 18 of these babies. Current build. MLK: 65 bytes leaked at 0x11fb020 This memory was allocated from: malloc [rtlib.o] PR_Malloc [prmem.c:38] nsAllocatorImpl::Alloc(unsigned int) [nsAllocator.cpp:82] nsAllocator::Alloc(unsigned int) [nsAllocator.cpp:148] nsStr::Alloc(nsStr&,unsigned int) [nsStr.cpp:663] nsStr::Realloc(nsStr&,unsigned int) [nsStr.cpp:690] nsStr::EnsureCapacity(nsStr&,unsigned int) [nsStr.cpp:100] nsStr::GrowCapacity(nsStr&,unsigned int) [nsStr.cpp:120] nsStr::Append(nsStr&,const nsStr&,unsigned int,int) [nsStr.cpp:166] nsStr::Assign(nsStr&,const nsStr&,unsigned int,int) [nsStr.cpp:146] nsCString::nsCString(const nsStr&) [nsString.cpp:100] nsString::ToNewCString()const [nsString2.cpp:645] nsBinaryInputStream::ReadStringZ(char**) [nsBinaryStream.cpp:308] nsCachedNetData::Deserialize(int) [nsCachedNetData.cpp:475] nsCachedNetData::Resurrect(nsINetDataCacheRecord*) [nsCachedNetData.cpp:373] nsReplacementPolicy::AssociateCacheEntryWithRecord(nsINetDataCacheRecord*,nsINetDataCache*,nsCachedNetData**) [nsReplacementPolicy.cpp:460] nsReplacementPolicy::GetCachedNetData(const char*,unsigned int,nsINetDataCache*,nsCachedNetData**) [nsReplacementPolicy.cpp:542] nsCacheManager::GetCachedNetData(const char*,const char*,unsigned int,unsigned int,nsICachedNetData**) [nsCacheManager.cpp:257] nsHTTPChannel::CheckCache() [nsHTTPChannel.cpp:754] nsHTTPChannel::Open() [nsHTTPChannel.cpp:1117] nsHTTPChannel::AsyncRead(unsigned int,int,nsISupports*,nsIStreamListener*) [nsHTTPChannel.cpp:276] nsDocumentOpenInfo::Open(nsIChannel*,int,const char*,nsISupports*) [nsURILoader.cpp:246] nsURILoader::OpenURIVia(nsIChannel*,int,const char*,nsISupports*,unsigned int) [nsURILoader.cpp:591] nsURILoader::OpenURI(nsIChannel*,int,const char*,nsISupports*) [nsURILoader.cpp:510] ImageNetContextImpl::GetURL(ilIURL*,NET_ReloadMethod,ilINetReader*) [nsImageNetContextAsync.cpp:751] IL_GetImage [if.cpp:2165] ImageRequestImpl::Init(void*,const char*,nsIImageRequestObserver*,const unsigned int*,unsigned int,unsigned int,unsigned int,ilINetContext*) [nsImageRequest.cpp:260] ImageGroupImpl::GetImage(const char*,nsIImageRequestObserver*,const unsigned int*,unsigned int,unsigned int,unsigned int) [nsImageGroup.cpp:266] nsFrameImageLoader::Init(nsIPresContext*,nsIImageGroup*,const nsString&,const unsigned int*,const nsSize*,nsIFrame*,unsigned int(*)(nsIPresContext*,nsIFrameImageLoader*,nsIFrame*,void*,unsigned int),void*) [nsFrameImageLoader.cpp:180] nsPresContext::StartLoadImage(const nsString&,const unsigned int*,const nsSize*,nsIFrame*,unsigned int(*)(nsIPresContext*,nsIFrameImageLoader*,nsIFrame*,void*,unsigned int),void*,nsIFrameImageLoader**) [nsPresContext.cpp:876]
Reporter | ||
Comment 1•24 years ago
|
||
An easier test case for this is to run: ./viewer -url http://www.cybersight.com/~bruce/index.html and exit. Using XPCOM_MEM_LEAK_LOG will then show a single nsCachedNetData created and it is subsequently leaked. Purify will _not_ show this leak directly.
Updated•24 years ago
|
Target Milestone: --- → M17
Updated•24 years ago
|
Status: NEW → RESOLVED
Closed: 24 years ago
Resolution: --- → DUPLICATE
You need to log in
before you can comment on or make changes to this bug.
Description
•