Closed Bug 963519 Opened 11 years ago Closed 10 years ago

Stop using Object.prototype.__proto__ because of bug 948227

Categories

(Chat Core :: General, defect)

defect
Not set
minor

Tracking

(Not tracked)

RESOLVED FIXED

People

(Reporter: clokep, Assigned: clokep)

References

Details

(Whiteboard: [1.6-blocking])

Attachments

(5 files, 1 obsolete file)

Apparently Florian had provided a complete list and I missed it: chat/modules/imContentSink.jsm:194: aResult.tags.__proto__ = aBase.tags; chat/modules/imContentSink.jsm:195: aResult.attrs.__proto__ = aBase.attrs; chat/modules/imContentSink.jsm:196: aResult.styles.__proto__ = aBase.styles; chat/modules/imThemes.jsm:92: this.__proto__ = HTMLTheme_prototype; chat/protocols/jsTest/jsTestProtocol.js:34:Conversation.prototype.__proto__ = GenericConvIMPrototype; chat/protocols/jsTest/jsTestProtocol.js:72:Account.prototype.__proto__ = GenericAccountPrototype; chat/protocols/jsTest/jsTestProtocol.js:93:jsTestProtocol.prototype.__proto__ = GenericProtocolPrototype; chat/protocols/yahoo/yahoo.js:75:YahooConversation.prototype.__proto__ = GenericConvIMPrototype; chat/protocols/yahoo/yahoo.js:143:YahooConference.prototype.__proto__ = GenericConvChatPrototype; chat/protocols/yahoo/yahoo.js:155:YahooConferenceBuddy.prototype.__proto__ = GenericConvChatBuddyPrototype; chat/protocols/yahoo/yahoo.js:170:YahooAccountBuddy.prototype.__proto__ = GenericAccountBuddyPrototype; chat/protocols/yahoo/yahoo.js:522:YahooAccount.prototype.__proto__ = GenericAccountPrototype; im/components/ibConvStatsService.js:249: stats.__proto__ = ConversationStats.prototype; im/content/debug/fake/fake.js:376: this.__proto__ = aChatNick ? GenericConvChatPrototype : GenericConvIMPrototype;
Attached patch Part 1 (the easy ones) (obsolete) (deleted) — Splinter Review
Attachment #8365019 - Flags: review?(florian)
Attachment #8365019 - Flags: review?(florian) → review+
Attached patch Part 2 (imThemes.jsm) (deleted) — Splinter Review
Attachment #8390082 - Flags: review?(clokep)
Attachment #8390082 - Flags: review?(clokep) → review+
Looks like the following are left: > chat/modules/imContentSink.jsm:194: aResult.tags.__proto__ = aBase.tags; > chat/modules/imContentSink.jsm:195: aResult.attrs.__proto__ = aBase.attrs; > chat/modules/imContentSink.jsm:196: aResult.styles.__proto__ = aBase.styles; > im/components/ibConvStatsService.js:249: stats.__proto__ = ConversationStats.prototype; > im/content/debug/fake/fake.js:376: this.__proto__ = aChatNick ? GenericConvChatPrototype : GenericConvIMPrototype;
(In reply to Patrick Cloke [:clokep] from comment #4) > > chat/modules/imContentSink.jsm:194: aResult.tags.__proto__ = aBase.tags; > > chat/modules/imContentSink.jsm:195: aResult.attrs.__proto__ = aBase.attrs; > > chat/modules/imContentSink.jsm:196: aResult.styles.__proto__ = aBase.styles; I'll try to have a look at these. > > im/components/ibConvStatsService.js:249: stats.__proto__ = ConversationStats.prototype; nhnt11, can you look into this one? > > im/content/debug/fake/fake.js:376: this.__proto__ = aChatNick ? GenericConvChatPrototype : GenericConvIMPrototype; This one seems relatively easy. I think we can use Object.create, like the warning suggests.
Flags: needinfo?(nhnt11)
Attached patch Part 3 (Stats Service) (deleted) — Splinter Review
Attachment #8410492 - Flags: review?(florian)
Flags: needinfo?(nhnt11)
Attachment #8410492 - Flags: review?(florian) → review+
Whiteboard: [1.6-blocking]
Keywords: checkin-needed
Keywords: checkin-needed
Attached patch Part 4 (imContentSink.jsm) (deleted) — Splinter Review
Attachment #8451349 - Flags: review?(florian)
Attachment #8451349 - Flags: review?(florian) → review+
Anyone will to take a look at Fake or do we just not care enough since it isn't in the released product?
Attached patch Part 5 (fake.js) (deleted) — Splinter Review
Note: setting the review flag on clokep as he asked about Fake, but anybody should feel free to steal that trivial review. (In reply to Patrick Cloke [:clokep] from comment #8) > Anyone will to take a look at Fake or do we just not care enough since it > isn't in the released product? I'm hoping that Fake could become a basis for some future UI tests, so I would prefer that we don't break it. I've just had a quick look. Untested (but I don't think it's worth testing right now).
Attachment #8451544 - Flags: review?(clokep)
Attachment #8451544 - Flags: review?(clokep) → review+
Keywords: checkin-needed
Uploading an unbitrotted version of attachment 8365019 [details] [diff] [review]. These should all apply cleanly for checkin now. (Although the tree is closed.)
Assignee: nobody → clokep
Attachment #8365019 - Attachment is obsolete: true
Status: NEW → ASSIGNED
Attachment #8452581 - Flags: review+
Depends on: 1037974
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: