bug 397231: switch from throwing to calling error handler when encountering problems after an XMLHttpRequest completes so the microsummary service doesn't leak when it encounters those problems; r,a=mconnor
git-svn-id: svn://10.0.0.236/trunk@236958 18797224-902f-48f8-a5cc-f745e15eee43
This commit is contained in:
parent
a33fe8e6d4
commit
d7d7c5709c
@ -2065,8 +2065,10 @@ MicrosummaryResource.prototype = {
|
||||
if (request.responseXML) {
|
||||
this._isXML = true;
|
||||
// XXX Figure out the parsererror format and log a specific error.
|
||||
if (request.responseXML.documentElement.nodeName == "parsererror")
|
||||
throw(request.channel.originalURI.spec + " contains invalid XML");
|
||||
if (request.responseXML.documentElement.nodeName == "parsererror") {
|
||||
this._handleError(event);
|
||||
return;
|
||||
}
|
||||
this._content = request.responseXML;
|
||||
this._contentType = request.channel.contentType;
|
||||
this._loadCallback(this);
|
||||
@ -2110,8 +2112,10 @@ MicrosummaryResource.prototype = {
|
||||
// even prefer other windows, since there's less chance of any browser
|
||||
// window machinery like throbbers treating our load like one initiated
|
||||
// by the user.
|
||||
if (!window)
|
||||
throw(this._uri.spec + " can't parse; no browser window");
|
||||
if (!window) {
|
||||
this._handleError(event);
|
||||
return;
|
||||
}
|
||||
var document = window.document;
|
||||
var rootElement = document.documentElement;
|
||||
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user