Closed Bug 203592 Opened 23 years ago Closed 23 years ago

Memory leak of 222 bytes from 6 blocks allocated in PL_strdup

Categories

(SeaMonkey :: MailNews: Address Book & Contacts, defect)

x86
Windows 2000
defect
Not set
normal

Tracking

(Not tracked)

VERIFIED DUPLICATE of bug 203593

People

(Reporter: stephend, Assigned: sspitzer)

Details

(Keywords: memory-leak)

Build: Latest trunk pull on Windows 2000 under Purify. Steps to Reproduce: 1. mozilla.exe -addressbook 2. Click 'New Card' 3. Type "S" into any field. 4. Hit Save. [W] MLK: Memory leak of 222 bytes from 6 blocks allocated in PL_strdup Distribution of leaked blocks Allocation location malloc [dbgheap.c:129] PL_strdup [strdup.c:46] l = PL_strlen(s); => rv = (char *)malloc(l+1); if( (char *)0 == rv ) return rv; if( (const char *)0 == s ) nsCRT::strdup(char const*) [nsCRT.h:172] DIR_GetStringPref [nsDirPrefs.cpp:2006] else { PR_FREEIF(value); /* the pref may have generated an error but we still might have something in value...... */ => value = defaultValue ? nsCRT::strdup(defaultValue) : nsnull; } return value; } DIR_GetPrefsForOneServer(DIR_Server *,int,int) [nsDirPrefs.cpp:2885] /* load in the column attributes */ if (server->dirType == PABDirectory) => server->columnAttributes = DIR_GetStringPref(prefstring, "columns", tempstring, kDefaultPABColumnHeaders); else server->columnAttributes = DIR_GetStringPref(prefstring, "columns", tempstring, kDefaultLDAPColumnHeaders); nsAbDirProperty::GetDirectoryProperties(nsIAbDirectoryProperties * *) [nsAbDirProperty.cpp:330] rv = GetDirPrefId(prefId); NS_ENSURE_SUCCESS(rv,rv); server->prefName = nsCRT::strdup(prefId.get()); => DIR_GetPrefsForOneServer(server, PR_FALSE, PR_FALSE); // Now create the obj and move info in DIR_Server to it. nsCOMPtr <nsIAbDirectoryProperties> properties; nsAbDirectoryDataSource::createDirectoryTreeNameSortNode(nsIAbDirectory *,nsIRDFNode * *) [nsDirectoryDataSource.cpp:712] // Get directory type. nsCOMPtr <nsIAbDirectoryProperties> properties; => rv = directory->GetDirectoryProperties(getter_AddRefs(properties)); NS_ENSURE_SUCCESS(rv,rv); PRUint32 dirType; rv = properties->GetDirType(&dirType); nsAbDirectoryDataSource::createDirectoryNode(nsIAbDirectory *,nsIRDFResource *,nsIRDFNode * *) [nsDirectoryDataSource.cpp:578] if ((kNC_IsWriteable == property)) rv = createDirectoryIsWriteableNode(directory, target); if ((kNC_DirTreeNameSort == property)) => rv = createDirectoryTreeNameSortNode(directory, target); return rv; } nsAbDirectoryDataSource::GetTarget(nsIRDFResource *,nsIRDFResource *,int,nsIRDFNode * *) [nsDirectoryDataSource.cpp:219] nsCOMPtr<nsIAbDirectory> directory(do_QueryInterface(source, &rv)); if (NS_SUCCEEDED(rv) && directory) => rv = createDirectoryNode(directory, property, target); else return NS_RDF_NO_VALUE; return rv; CompositeDataSourceImpl::GetTarget(nsIRDFResource *,nsIRDFResource *,int,nsIRDFNode * *) [nsCompositeDataSource.cpp:825] for (PRInt32 i = 0; i < count; ++i) { nsresult rv; rv = mDataSources[i]->GetTarget(aSource, aProperty, aTruthValue, => aResult); if (NS_FAILED(rv)) return rv;
QA Contact: nbaca → technutz
mass re-assign.
Assignee: racham → sspitzer
marking dup this should be fixed by the patch to bug 203593. *** This bug has been marked as a duplicate of 203593 ***
Status: NEW → RESOLVED
Closed: 23 years ago
Resolution: --- → DUPLICATE
verified dup
Status: RESOLVED → VERIFIED
Product: Browser → Seamonkey
You need to log in before you can comment on or make changes to this bug.