Bug 158584

Summary: firefox saves files always as attachment.cgi
Product: [openSUSE] openSUSE 10.3 Reporter: Olaf Hering <ohering>
Component: FirefoxAssignee: E-mail List <bnc-team-mozilla>
Status: RESOLVED FIXED QA Contact: E-mail List <qa-bugs>
Severity: Major    
Priority: P5 - None CC: sbrabec, vuntz, wolfgang
Version: Alpha 0plusKeywords: should_go_upstream
Target Milestone: ---   
Hardware: PowerPC   
OS: Linux   
Whiteboard:
Found By: Development Services Priority:
Business Priority: Blocker: ---
Marketing QA Status: --- IT Deployment: ---

Description Olaf Hering 2006-03-16 10:22:58 UTC
firefox saves files always as "attachment.cgi"
mozilla as shipped with opensuse 10.0 got that right, it picked the correct filename from the bugzilla attachment preferences.
Comment 1 Olaf Hering 2006-03-16 10:26:25 UTC
seems to happen with 'save link target as...'

in the 'edit attachment preferences' there is a download link, which stores the file in ~/Desktop

the 'save link target as...' will store it in the userdefined directory, which is not ~/Desktop in my case.
Comment 2 Stanislav Brabec 2006-03-16 12:03:33 UTC
Filename for save is sent by the server in the "Content-Disposition" header. If it is not present, I guess that firefox uses a heuristics.
Comment 3 Wolfgang Rosenauer 2006-03-16 12:14:40 UTC
"Save link target as" is different from a direct click on the link.
So did you compare the same things and which one is different and why is it not possible to use the direct click?
So please describe exactly what you do and what you expect and if Firefox 1.0.x really had another behaviour.
Comment 4 Olaf Hering 2006-03-16 12:31:18 UTC
I do know that 'save bugreportattachment to local disk...' always worked. Until I upgraded to 10.1, which forced me to switch from mozilla to firefox.

just go to a random bug which has an attachment. dont click on the [edit] link but on the one left from it and try to save it to disk. I tried it with a 10.0 fresh install. firefox picks the right filename.
I tried it with a sles10 beta8 fresh install, firefox picks attachment.cgi.
Comment 5 Robert O'Callahan 2006-04-04 03:20:32 UTC
I believe this was a consequence of this upstream change:

http://bugzilla.mozilla.org/show_bug.cgi?id=249759

There's a tradeoff here --- waiting for the server response means we have to delay popping up the dialog --- so I'll try to find out if this change was intended or not.
Comment 6 Robert O'Callahan 2006-04-04 03:21:17 UTC
Er, that's https://bugzilla.mozilla.org/show_bug.cgi?id=294759
Comment 7 Robert O'Callahan 2006-04-04 05:43:52 UTC
Actually it was a deliberate change in
https://bugzilla.mozilla.org/show_bug.cgi?id=160454

See https://bugzilla.mozilla.org/show_bug.cgi?id=299372 for the upstream version of this bug.

I'm not really sure what to do here. 
Comment 8 Matthias Fruehauf 2006-05-09 15:38:07 UTC
Any update?
Comment 9 Olaf Hering 2006-10-22 11:57:20 UTC
they also broke seamonkey.
Comment 10 Wolfgang Rosenauer 2006-10-22 16:31:33 UTC
It's upstream behaviour but discussion is still going on to fix it the right way.
Comment 11 Magnus Boman 2007-05-01 01:16:44 UTC
This is still happening in SLED10SP1 and 10.3. Moving to 10.3
Comment 12 JP Rosevear 2007-07-31 16:09:49 UTC
This was a core intentional upstream change.  We won't back port it, we'll just get it for FF 3.
Comment 13 Olaf Hering 2008-05-07 12:09:39 UTC
still broken in firefox 3.0 beta5.
right click on first attachment in bug #387257, save link target as...
I get attachment.cgi
Comment 14 Wolfgang Rosenauer 2008-05-07 20:15:06 UTC
It's already fixed in upcoming FF 3.0rc1 but wasn't when beta 5 was cut.
3.0b5 is somewhat frozen for us because of the dependency to mozilla-nss and therefore crypto freeze.
It doesn't even make sense to backport all this to 3.0b5 since we are talking about (currently) 451 fixed bugs in Firefox between 3.0b5 and rc1.

So as soon as 11.0 is GA we will provide an online update to the latest Firefox version out at that point.
Comment 15 Olaf Hering 2008-07-17 12:20:36 UTC
it is still not working for me wit 3.0 final.

see attachments in https://bugzilla.novell.com/show_bug.cgi?id=324134
right mouse click on the non-obsolete patches, all I get is attachment.cgi
Comment 16 Olaf Hering 2008-07-17 12:23:12 UTC
weird, for some reason the first two attachment were offered as attachment.cgi.
But now I get always the filename.
Comment 17 Wolfgang Rosenauer 2008-07-17 12:32:47 UTC
There is a timeout and when the server doesn't tell the filename within that time it doesn't wait longer but uses attachment.cgi (in that case).
pref("browser.download.saveLinkAsFilenameTimeout", 1000);

That may explain what you are seeing.
Comment 18 Olaf Hering 2008-07-17 12:37:04 UTC
I will try 10000 and see if that helps.
Comment 19 Vincent Untz 2009-08-05 13:51:46 UTC
Olaf: can we close the bug now?
Comment 21 Vincent Untz 2009-08-06 11:44:29 UTC
Okay, assuming it's fixed since Olaf isn't here anymore. People disagreeing should feel free to reopen.