If you think a bug might affect users in the 57 release, please set the correct tracking and status flags for Release Management.

NS_ERROR_IN_PROGRESS when setting nsIXMLHttpRequest.mozBackgroundRequest in xmpp/transportLayer.js

RESOLVED INVALID

Status

Cloud Services
General
RESOLVED INVALID
9 years ago
8 years ago

People

(Reporter: myk, Unassigned)

Tracking

unspecified
Future
x86
Linux
Points:
---

Firefox Tracking Flags

(Not tracked)

Details

Attachments

(1 attachment)

(Reporter)

Description

9 years ago
The following error message appeared in my JS console today:

Error: [Exception... "Component returned failure code: 0x804b000f (NS_ERROR_IN_PROGRESS) [nsIXMLHttpRequest.mozBackgroundRequest]"  nsresult: "0x804b000f (NS_ERROR_IN_PROGRESS)"  location: "JS frame :: file:///home/myk/Projects/weave/modules/xmpp/transportLayer.js :: anonymous :: line 259"  data: no]
Source File: file:///home/myk/Projects/weave/modules/xmpp/transportLayer.js
Line: 259

It looks like _doPost was called, reused this._request, and then tried to set mozBackgroundRequest on it (per my recent change), but this._request was "in progress", so that flag couldn't be set.

There is at least one and perhaps two bugs here:

1. We should set mozBackgroundRequest when we first define this._request rather than every time _doPost uses it.

2. Perhaps _doPost needs to make sure that this._request isn't in use before trying to use it for something else.
(Reporter)

Comment 1

9 years ago
Created attachment 326512 [details] [diff] [review]
patch v1: fixes first problem

This fixes the first problem.  I'm not sure how to go about figuring out the second.

Note: this patch also uses an instance getter and a closure to avoid storing the request object in a second property.

Comment 2

9 years ago
Setting milestone to 0.3.
Target Milestone: -- → 0.3

Comment 3

9 years ago
These bugs need to be triaged, removing 0.3 milestone setting.
Target Milestone: 0.3 → Future

Updated

8 years ago
Component: Weave → General
Product: Mozilla Labs → Weave
QA Contact: weave → general
xmpp is currently dead (and hg removed).
Status: NEW → RESOLVED
Last Resolved: 8 years ago
Resolution: --- → INVALID
You need to log in before you can comment on or make changes to this bug.