Closed Bug 286188 Opened 20 years ago Closed 19 years ago

leaks during profile migration

Categories

(SeaMonkey :: Startup & Profiles, defect)

defect
Not set
normal

Tracking

(Not tracked)

RESOLVED FIXED

People

(Reporter: ajschult784, Assigned: ajschult784)

Details

(Keywords: memory-leak)

Attachments

(1 file, 1 obsolete file)

There are a few in nsPrefMigration.cpp and another couple in nsProfileAccess.cpp.
Attached patch patch (obsolete) (deleted) — Splinter Review
Attachment #177457 - Flags: superreview?(dbaron)
Attachment #177457 - Flags: review?(timeless)
Comment on attachment 177457 [details] [diff] [review] patch >+ PR_Free(folderName); nsCRT::free >+ PR_Free(folderName); ditto, and same for the next too And in all three cases cases folderName should move inside the loop.
Attachment #177457 - Flags: superreview?(dbaron) → superreview+
> >+ PR_Free(folderName); > > nsCRT::free ok. FYI: http://lxr.mozilla.org/mozilla/source/xpcom/obsolete/nsFileSpec.h#290 (although I did see at least one place where nsCRT::free was used)
Was I mixing up GetLeaf and GetLeafName? Or is the comment on one of them wrong?
oh. right. sorry. it's GetLeafName, which is supposed to be used with nsCRT:free
Comment on attachment 177457 [details] [diff] [review] patch >RCS file: /cvsroot/mozilla/profile/pref-migrator/src/nsPrefMigration.cpp,v >+++ pref-migrator/src/nsPrefMigration.cpp 15 Mar 2005 06:00:06 -0000 >@@ -1482,32 +1482,29 @@ nsPrefMigration::GetSizes(nsFileSpec inp >- if (nsCStringEndsWith(fileOrDirNameStr, MAIL_SUMMARY_SUFFIX_IN_4x) || nsCStringEndsWith(fileOrDirNameStr, NEWS_SUMMARY_SUFFIX_IN_4x) || nsCStringEndsWith(fileOrDirNameStr, SUMMARY_SUFFIX_IN_5x)) /* Don't copy the summary files */ >- continue; >- else >+ if (!nsCStringEndsWith(fileOrDirNameStr, MAIL_SUMMARY_SUFFIX_IN_4x) && !nsCStringEndsWith(fileOrDirNameStr, NEWS_SUMMARY_SUFFIX_IN_4x) && !nsCStringEndsWith(fileOrDirNameStr, SUMMARY_SUFFIX_IN_5x)) /* Don't copy the summary files */ Hmm, I know you did not do the original line, but while touching it, why not adhere to the 80 char line limit?
Attachment #177457 - Flags: review?(timeless) → review+
Attached patch patch v2 (deleted) — Splinter Review
updated to address dbaron's comments
Attachment #177457 - Attachment is obsolete: true
fixed
Status: NEW → RESOLVED
Closed: 19 years ago
Resolution: --- → FIXED
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: