Closed Bug 716491 Opened 12 years ago Closed 10 years ago

Investigate the status code for non-HTTP XHR.

Categories

(Core :: DOM: Core & HTML, defect)

defect
Not set
normal

Tracking

()

RESOLVED FIXED
mozilla35
Tracking Status
relnote-firefox --- 35+
relnote-b2g --- ?

People

(Reporter: emk, Assigned: bzbarsky)

References

Details

(Keywords: dev-doc-complete)

Attachments

(2 files)

Currently we returns 0 instead of 200 for successful non-HTTP responses.
Attached file Test case
blob data
  0    0       Firefox Nightly + bug 702820 patch
  0    0       Opera 11.60
200  Exception Chrome
200  Exception IE 10 PP3
(In reply to Masatoshi Kimura [:emk] from comment #1)
> 200  Exception Chrome
> 200  Exception IE 10 PP3

Cool. There is precedent. Let's do this.
IMO it would be strange to get http codes for non-http XHR, but if IE and webkit does that too,
I'm ok with the change.
annevk pointed to http://dev.w3.org/2006/webapi/FileAPI/#processingModel for blob:, so our current blob: behavior is clearly wrong.
I'll take this
Assignee: nobody → jonas
Under http://fetch.spec.whatwg.org/#basic-fetch this is mostly defined. Feedback welcome. And e.g. when not stated otherwise, a response's status is by default 200.
I see.  That helps, yes.
Assignee: jonas → bzbarsky
Status: NEW → ASSIGNED
Attachment #8484303 - Flags: review?(bugs) → review+
https://hg.mozilla.org/integration/mozilla-inbound/rev/4934b1907579
Flags: in-testsuite+
Target Milestone: --- → mozilla35
https://hg.mozilla.org/mozilla-central/rev/4934b1907579
Status: ASSIGNED → RESOLVED
Closed: 10 years ago
Resolution: --- → FIXED
Release Note Request (optional, but appreciated)
[Why is this notable]: possibly breaking code that assumes false behaviour
[Suggested wording]: Non-HTTP(S) XHR now returns correct status code.
[Links (documentation, blog post, etc)]:
relnote-firefox: --- → ?
relnote-b2g: --- → ?
Flags: needinfo?(bzbarsky)
Flags: needinfo?(bzbarsky)
Depends on: 1151728
Release note already updated (by lsblakk, I think) - https://developer.mozilla.org/en-US/Firefox/Releases/35#InterfacesAPIsDOM

Removing dev-doc-needed.
Keywords: dev-doc-needed
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: