From 3a8349defa563709e82cf7d90a88510edc831951 Mon Sep 17 00:00:00 2001 From: "Carsten \"Tomcat\" Book" Date: Tue, 3 Dec 2013 12:53:08 +0100 Subject: [PATCH] Backed out changeset bc9014b4439a (bug 929067) for test failures in B2g Desktop Linux & B2G ICS Emulator Opt --- toolkit/components/jsdownloads/src/DownloadCore.jsm | 9 +++------ 1 file changed, 3 insertions(+), 6 deletions(-) diff --git a/toolkit/components/jsdownloads/src/DownloadCore.jsm b/toolkit/components/jsdownloads/src/DownloadCore.jsm index 1252f83efa3..902caee3069 100644 --- a/toolkit/components/jsdownloads/src/DownloadCore.jsm +++ b/toolkit/components/jsdownloads/src/DownloadCore.jsm @@ -363,22 +363,19 @@ this.Download.prototype = { // This function propagates progress from the DownloadSaver object, unless // it comes in late from a download attempt that was replaced by a new one. - // If the cancellation process for the download has started, then the update - // is ignored. function DS_setProgressBytes(aCurrentBytes, aTotalBytes, aHasPartialData) { - if (this._currentAttempt == currentAttempt) { + if (this._currentAttempt == currentAttempt || !this._currentAttempt) { this._setBytes(aCurrentBytes, aTotalBytes, aHasPartialData); } } // This function propagates download properties from the DownloadSaver // object, unless it comes in late from a download attempt that was - // replaced by a new one. If the cancellation process for the download has - // started, then the update is ignored. + // replaced by a new one. function DS_setProperties(aOptions) { - if (this._currentAttempt != currentAttempt) { + if (this._currentAttempt && this._currentAttempt != currentAttempt) { return; }