Closed
Bug 704711
Opened 14 years ago
Closed 14 years ago
Using httpd module raises some warnings about "reference to undefined property Ci.nsIHttpServer"
Categories
(Add-on SDK Graveyard :: General, defect, P2)
Add-on SDK Graveyard
General
Tracking
(Not tracked)
RESOLVED
FIXED
People
(Reporter: KWierso, Assigned: KWierso)
Details
Attachments
(1 file)
(C:\Users\kwierso\mysdkfork\addon-sdk) C:\Users\kwierso\mysdkfork\addon-sdk\packages\addon-kit>cfx test --filter test-request
Using binary at 'C:\Program Files (x86)\Mozilla Firefox\firefox.exe'.
Using profile at 'c:\users\kwierso\appdata\local\temp\tmpej2dvt.mozrunner'.
Running tests on Firefox 8.0/Gecko 8.0 ({ec8030f7-c20a-464f-9b0e-13a3a9e97384}) under winnt/x86-msvc
.
.console: [JavaScript Warning: "reference to undefined property Ci.nsIHttpServer" {file: "resource:/
/5ca83afc-c51d-4f59-bf0f-32bdbabc2778-at-jetpack-api-utils-lib/cuddlefish.js -> resource://5ca83afc-
c51d-4f59-bf0f-32bdbabc2778-at-jetpack-api-utils-lib/httpd.js" line: 704}]
.console: [JavaScript Warning: "reference to undefined property Ci.nsIHttpServer" {file: "resource:/
/5ca83afc-c51d-4f59-bf0f-32bdbabc2778-at-jetpack-api-utils-lib/cuddlefish.js -> resource://5ca83afc-
c51d-4f59-bf0f-32bdbabc2778-at-jetpack-api-utils-lib/httpd.js" line: 704}]
.console: [JavaScript Error: "no element found" {file: "http://localhost/safebrowsing-dummy/newkey"
line: 1}]
...console: [JavaScript Warning: "reference to undefined property Ci.nsIHttpServer" {file: "resource
://5ca83afc-c51d-4f59-bf0f-32bdbabc2778-at-jetpack-api-utils-lib/cuddlefish.js -> resource://5ca83af
c-c51d-4f59-bf0f-32bdbabc2778-at-jetpack-api-utils-lib/httpd.js" line: 704}]
.console: [JavaScript Warning: "reference to undefined property Ci.nsIHttpServer" {file: "resource:/
/5ca83afc-c51d-4f59-bf0f-32bdbabc2778-at-jetpack-api-utils-lib/cuddlefish.js -> resource://5ca83afc-
c51d-4f59-bf0f-32bdbabc2778-at-jetpack-api-utils-lib/httpd.js" line: 704}]
.....console: [JavaScript Warning: "reference to undefined property Ci.nsIHttpServer" {file: "resour
ce://5ca83afc-c51d-4f59-bf0f-32bdbabc2778-at-jetpack-api-utils-lib/cuddlefish.js -> resource://5ca83
afc-c51d-4f59-bf0f-32bdbabc2778-at-jetpack-api-utils-lib/httpd.js" line: 704}]
..warning: 6 warnings or errors were logged to the platform's nsIConsoleService, which could be of n
o consequence; however, they could also be indicative of aberrant behavior.
The function doing this is QueryInterface:
// NSISUPPORTS
//
// see nsISupports.QueryInterface
//
QueryInterface: function(iid)
{
if (iid.equals(Ci.nsIHttpServer) ||
iid.equals(Ci.nsIServerSocketListener) ||
iid.equals(Ci.nsISupports))
return this;
throw Cr.NS_ERROR_NO_INTERFACE;
},
Is this another instance where require("chrome") isn't giving us the correct reference to Ci? (Like bug 683217 was for Cu?)
Replacing "Ci" with "components.interfaces" raises the same warning.
| Assignee | ||
Comment 1•14 years ago
|
||
Hrm, actually, when I type "Components.interfaces.nsISupports" into the error console's "Code" box and evaluate it, it logs "nsISupports".
But when I type in "Components.interfaces.nsIHttpServer", it doesn't do anything.
| Assignee | ||
Updated•14 years ago
|
Priority: -- → P2
Comment 2•14 years ago
|
||
I think nsIHttpServer just doesn't exist in normal builds. I think it gets defined for xpcshell where httpd.js normally lives so this is an accurate warning but probably not anything more sinister. Chances are we could remove that line.
Priority: P2 → --
Updated•14 years ago
|
Priority: -- → P2
| Assignee | ||
Updated•14 years ago
|
OS: Windows NT → All
Hardware: x86_64 → All
| Assignee | ||
Comment 3•14 years ago
|
||
So this pull request removes the reference to nsIHttpServer, and running the request tests no longer spews a bunch of junk about nsIHttpServer.
nsIHttpServer IS still referenced a ton in httpd.js's comments, though. Not sure whether that's important or not, since I didn't write the file, I just copied it over.
Attachment #581087 -
Flags: review?(dtownsend)
Comment 4•14 years ago
|
||
Comment on attachment 581087 [details]
Pointer to pull request 302
Yeah after looking it seems that that interface only exists to allow you to use the http server through XPCOM, since we obviously aren't doing that it is unnecessary).
Attachment #581087 -
Flags: review?(dtownsend) → review+
Comment 5•14 years ago
|
||
Commit pushed to https://github.com/mozilla/addon-sdk
https://github.com/mozilla/addon-sdk/commit/968431c6c3cca0eee4e732fa74d8bda5758327d9
Merge pull request #302 from KWierso/httpd
fix Bug 704711 - Remove reference to nsIHttpServer
Updated•14 years ago
|
Assignee: nobody → kwierso
Status: NEW → RESOLVED
Closed: 14 years ago
Resolution: --- → FIXED
You need to log in
before you can comment on or make changes to this bug.
Description
•