Closed Bug 1709579 Opened 4 years ago Closed 3 years ago

Switch to using Services.io in chatZilla

Categories

(SeaMonkey :: Chat, task)

Tracking

(seamonkey2.53+ fixed)

RESOLVED FIXED
seamonkey 2.88
Tracking Status
seamonkey2.53 + fixed

People

(Reporter: iannbugzilla, Assigned: iannbugzilla)

Details

(Whiteboard: SM2.53.9)

Attachments

(1 file, 2 obsolete files)

Rather than storing io service in client.iosvc or similar just make use of Services.io
At the same time remove old code around use of URLSpec and port:

  • Bug 1329958 - remove trailing newURI null parameters in comm-central
Attached patch 1709579-irc-iosvc-2538.patch (obsolete) — Splinter Review

[Approval Request Comment]
Regression caused by (bug #): n/a
User impact if declined: none
Testing completed (on m-c, etc.): 2.53.8
Risk to taking this patch (and alternatives if risky): low
String changes made by this patch: none

Attachment #9220331 - Flags: review?(frgrahl)
Attachment #9220331 - Flags: approval-comm-release?
Attachment #9220331 - Flags: approval-comm-esr60?
Attached patch 1709579-irc-iosvc-2539.patch (obsolete) — Splinter Review

Removed a now unused const

Attachment #9220331 - Attachment is obsolete: true
Attachment #9220331 - Flags: review?(frgrahl)
Attachment #9220331 - Flags: approval-comm-release?
Attachment #9220331 - Flags: approval-comm-esr60?
Attachment #9220954 - Flags: review?(frgrahl)
Attachment #9220954 - Flags: approval-comm-release?
Attachment #9220954 - Flags: approval-comm-esr60?
Whiteboard: SM2.53.9

Comment on attachment 9220954 [details] [diff] [review]
1709579-irc-iosvc-2539.patch

suite/extensions/irc/js/lib/connection-xpcom.js
suite/extensions/irc/js/lib/utils.js
suite/extensions/irc/xul/content/commands.js
suite/extensions/irc/xul/content/handlers.js
suite/extensions/irc/xul/content/nsDragAndDrop.js

NIT: Does not import Services but seems to pick it up from another file.

suite/extensions/irc/xul/content/commands.js
This probably works but SEC_NORMAL looks risky and is gone from later releases:

  •            var channel = Services.io.newChannel2(
    
  •                e.url, "UTF-8", null, null,
    
  •                Services.scriptSecurityManager.getSystemPrincipal(),
    
  •                null, Ci.nsILoadInfo.SEC_NORMAL,
    
  •                Ci.nsIContentPolicy.TYPE_OTHER);
    

Would probably use Services.io.newChannelFromURI( otherwise needs to be fixed up for 2.57 and up because newChannel2 is gone. But would need a uri not an url.

Either way try Ci.nsILoadInfo.SEC_ALLOW_CROSS_ORIGIN_DATA_IS_NULL instead of SEC_NORMAL.

r/a+ with issues fixed or discussed if not.

Attachment #9220954 - Flags: review?(frgrahl)
Attachment #9220954 - Flags: review+
Attachment #9220954 - Flags: approval-comm-release?
Attachment #9220954 - Flags: approval-comm-release+
Attachment #9220954 - Flags: approval-comm-esr60?
Attachment #9220954 - Flags: approval-comm-esr60+

Changed to Ci.nsILoadInfo.SEC_ALLOW_CROSS_ORIGIN_SEC_CONTEXT_IS_NULL
newChannel2 doesn't go away until 67 so okay to use in 2.53.x
Carrying forward r/a

Attachment #9220954 - Attachment is obsolete: true
Attachment #9229125 - Flags: review+
Attachment #9229125 - Flags: approval-comm-release+
Attachment #9229125 - Flags: approval-comm-esr60+

Pushed by frgrahl@gmx.net:
https://hg.mozilla.org/comm-central/rev/6de6dca432a6
Switch to using Services.io in chatZilla. r=frg

Status: ASSIGNED → RESOLVED
Closed: 3 years ago
Resolution: --- → FIXED
Target Milestone: --- → seamonkey 2.88
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: