nsPrefService::ReadAndOwnSharedUserPrefFile should use nsIFile.equals

RESOLVED INCOMPLETE

Status

P5
normal
RESOLVED INCOMPLETE
16 years ago
3 years ago

People

(Reporter: timeless, Assigned: ccarlen)

Tracking

Firefox Tracking Flags

(Not tracked)

Details

Attachments

(1 attachment)

(Reporter)

Description

16 years ago
nsresult nsPrefService::ReadAndOwnSharedUserPrefFile(nsIFile *aFile)
{
  NS_ENSURE_ARG(aFile);
  if (mCurrentSharedFile == aFile)
    return NS_OK;
  NS_IF_RELEASE(mCurrentSharedFile);

nsIFile is of course not an atom, but presumably this code is designed to avoid
reopening the same pref file. If that's the case then it should call Equals()
(Reporter)

Comment 1

15 years ago
Created attachment 134990 [details] [diff] [review]
like this
(Reporter)

Updated

15 years ago
Attachment #134990 - Flags: review?(bsmedberg)

Comment 2

15 years ago
Comment on attachment 134990 [details] [diff] [review]
like this

If you're gonna do it, do it all the way... see
http://lxr.mozilla.org/mozilla/source/modules/libpref/src/nsPrefService.cpp#508
and #543

And is there any reason we're not using a comptr here?

--BDS
Attachment #134990 - Flags: review?(bsmedberg) → review-
(Reporter)

Updated

13 years ago
Status: UNCONFIRMED → NEW
Ever confirmed: true
Priority: -- → P5
QA Contact: agracebush → profile-manager-backend

Comment 3

3 years ago
This bug is filed in a bugzilla component related to pre-Firefox code which no longer exists. I believe it is no longer relevant and I am therefore closing it INCOMPLETE.

If you believe that this bug is still valid and needs to be fixed, please reopen it and move it to the Toolkit:Startup and Profile System product/component.
No longer blocks: 1243899
Status: NEW → RESOLVED
Last Resolved: 3 years ago
Resolution: --- → INCOMPLETE
Product: Core → Core Graveyard
You need to log in before you can comment on or make changes to this bug.