Closed Bug 351920 Opened 18 years ago Closed 18 years ago

Remove uses of nsSpecialSystemDirectory from mailnews

Categories

(MailNews Core :: Backend, defect)

defect
Not set
normal

Tracking

(Not tracked)

RESOLVED FIXED

People

(Reporter: standard8, Assigned: standard8)

References

Details

Attachments

(3 files, 1 obsolete file)

nsSpecialSystemDirectory is obsolete (its in xpcom/obsolote ;-) ), there's not too many uses in mailnews so it should be fairly easy to remove. Additionally there's only one or two uses other than mailnews in the entire mozilla tree so we'll easily be able to remove it completely.
Blocks: 351921
Attached patch The fix v1 (obsolete) — Splinter Review
Replaces the uses of nsSpecialSystemDirectory with the new versions.

David - I'm going to run with this on linux for a while, any chance you could try a windows build?
this looks like a candidate for a helper function or two - as it is, your patch expands a fair bit of code inline, from what i can tell. 
Attached patch The fix v2Splinter Review
Same as previous, but includes helper functions where appropriate to make things a little easier.
Attachment #237461 - Attachment is obsolete: true
Attachment #238287 - Flags: review?(bienvenu)
Comment on attachment 238287 [details] [diff] [review]
The fix v2

+  {
+    if (tmpSpec)
+      delete tmpSpec;
 
no need for the if - delete checks for null.

otherwise, this looks good. It won't be until later that I'll have a chance to compile this on windows, however.
Attachment #238287 - Flags: review?(bienvenu) → review+
Comment on attachment 238287 [details] [diff] [review]
The fix v2

Requesting sr, I'll address David's comment on check-in. Hopefully he'll have tested it by then as well ;-)
Attachment #238287 - Flags: superreview?(mscott)
Comment on attachment 238287 [details] [diff] [review]
The fix v2

assuming you add David's comments.

Thanks for taking this on!
Attachment #238287 - Flags: superreview?(mscott) → superreview+
Standard8, here are replacement diffs to get this to compile on windows.
Attached patch One more includeSplinter Review
Checked in the first two patches.

One #include remains in mailnews :-(
Attachment #238763 - Flags: superreview?(bienvenu)
Attachment #238763 - Flags: review?(bienvenu)
Comment on attachment 238763 [details] [diff] [review]
One more include

you need to add #include "plstr.h" if you remove that include - sr=bienvenu if you do that.

thx for the patch!
Attachment #238763 - Flags: superreview?(bienvenu)
Attachment #238763 - Flags: superreview-
Attachment #238763 - Flags: review?(bienvenu)
Attachment #238763 - Flags: review-
(In reply to comment #9)
> (From update of attachment 238763 [details] [diff] [review] [edit])
> you need to add #include "plstr.h" if you remove that include - sr=bienvenu if
> you do that.
> 
> thx for the patch!
> 
Checked in with the additional include. That's it from mailnews :-)
Status: NEW → RESOLVED
Closed: 18 years ago
Resolution: --- → FIXED
Depends on: 353915
Depends on: 353073
Product: Core → MailNews Core
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: