Closed Bug 392793 Opened 17 years ago Closed 17 years ago

invalid (negative) progress percentage displayed in the window title for certain downloads

Categories

(Toolkit :: Downloads API, defect)

defect
Not set
minor

Tracking

()

VERIFIED FIXED
mozilla1.9alpha8

People

(Reporter: asqueella, Assigned: sciguyryan)

Details

(Keywords: regression)

Attachments

(1 file)

Works for me.
in the latest trunk with the new download manager, I see 'unknown time left'.
Ditto here, with Mozilla/5.0 (Windows; U; Windows NT 6.0; en-US; rv:1.9a8pre) Gecko/2007081905 Minefield/3.0a8pre (I see what Jo sees); this WFM.

Nickolay, is this with a corrupted downloads.sqlite file?
Stephen: No, this is with a clean profile.

'Unknown time left' is indeed shown next to the specific item, but the window title has this wrong progress value. I just tested with 2007081905, this is WinXP.
Summary: invalid (negative) progress percentage displayed for certain downloads → invalid (negative) progress percentage displayed in the window title for certain downloads
Attached patch Try v1.0Splinter Review
Try v1.0

Is this what we need?
Assignee: nobody → sciguyryan
Status: NEW → ASSIGNED
Attachment #277401 - Flags: review?(comrade693+bmo)
It would also be worth checking if the MAX_INT -> -1 mapping for PRUint64 return type is intended...
Brian, is it the intended behavior of the JS engine to map LL_MAXUINT to -1?
There is no -1 in unsigned-land.  So, likely yes.
Comment on attachment 277401 [details] [diff] [review]
Try v1.0

r=sdwilsh
Attachment #277401 - Flags: review?(comrade693+bmo) → review+
Because this is front end and has a r+ does that mean I can put up a checkin request on it or does it need a second review or whatnot?
(In reply to comment #7)
> Brian, is it the intended behavior of the JS engine to map LL_MAXUINT to -1?

It's XPConnect, not the JS engine. See

http://lxr.mozilla.org/mozilla/source/js/src/xpconnect/src/xpcconvert.cpp#177

/be
(In reply to comment #10)
> Because this is front end and has a r+ does that mean I can put up a checkin
> request on it or does it need a second review or whatnot?
My review should be sufficient here.  If I ever feel it isn't, I'll let you know.  Since this is a Firefox UI thing, it also does not need approval yet.
Keywords: checkin-needed
OS: Windows XP → All
Hardware: PC → All
mozilla/toolkit/mozapps/downloads/content/downloads.js  1.84

Now showing "100% of 1 file" in this case.. certainly better than -12345%!
Status: ASSIGNED → NEW
Keywords: checkin-needed
Target Milestone: --- → Firefox 3 M8
Status: NEW → RESOLVED
Closed: 17 years ago
Resolution: --- → FIXED
Flags: in-testsuite-
Flags: in-litmus?
http://litmus.mozilla.org/show_test.cgi?id=4596

in-litmus+

If you'd be so kind as to review the testcase when you get a chance, I'd appreciate it!
Flags: in-litmus? → in-litmus+
The test case looks fine, except for me the link cannot be saved as neither on 2.0, nor on a self-built trunk... Don't have the time to track down whether it's due to something in my profile or because of a Firefox bug.
(In reply to comment #15)
> The test case looks fine, except for me the link cannot be saved as neither on
> 2.0, nor on a self-built trunk... Don't have the time to track down whether
> it's due to something in my profile or because of a Firefox bug.

I couldn't save it either, which actually means it's probably a good testcase :-) 

(In reply to comment #16)
> (In reply to comment #15)
> > The test case looks fine, except for me the link cannot be saved as neither on
> > 2.0, nor on a self-built trunk... Don't have the time to track down whether
> > it's due to something in my profile or because of a Firefox bug.
> 
> I couldn't save it either, which actually means it's probably a good testcase
> :-) 

Looks like this is a regression; bug 393895.

(In reply to comment #17)
> (In reply to comment #16)
> > (In reply to comment #15)
> > > The test case looks fine, except for me the link cannot be saved as neither on
> > > 2.0, nor on a self-built trunk... Don't have the time to track down whether
> > > it's due to something in my profile or because of a Firefox bug.
> > 
> > I couldn't save it either, which actually means it's probably a good testcase
> > :-) 
> 
> Looks like this is a regression; bug 393895.

I don't really think it's the same bug, actually, so I spun off bug 394278.
Verified FIXED with Mozilla/5.0 (Windows; U; Windows NT 6.0; en-US; rv:1.9a8pre) Gecko/2007082923 Minefield/3.0a8pre; although it goes fast.  Bug 394278's testcase would be the best testcase, but I want to get this verified so we'll know in the future if and when it does regress.

I see it quickly jump from 70% or so to "100% of 1 file", even though it's still downloading, but I don't see the negative percentage in comment 0 and comment 3.
Status: RESOLVED → VERIFIED
Product: Firefox → Toolkit
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: