"Auto Detect" for attachment content type.

Benton, Kevin kevin.benton at amd.com
Thu Apr 6 15:09:08 UTC 2006


> On Wed, 2006-04-05 at 21:28 -0400, David Miller wrote:
> > byron jones wrote on 4/5/06 9:00 PM:
> > >>> buglist.cgi: -content_disposition => "$disp;
filename=$filename");
> > >> Just figured out there's a potential bug there - $filename should
> have
> > >> "'s around it.
> > >
> > > and encoded if it's more than 78 chars, or non-ascii.
> >
> > please research old bugs before touching this.
> >
> > It was broken on several browsers a year or two ago, and it got
> > researched the hell out of to find out how to do it right.  If it's
> > broken now, someone probably reverted it on accident.  Otherwise,
it's
> > likely the way it is now on purpose.
> 
> 	The way it is now is fine. :-) The line I pasted above is from
> buglist.cgi. *We* set all the filenames on buglist.cgi.
> 
> 	attachment.cgi does the exact right thing with user-supplied
> filenames.

The problem I see is Firefox doesn't handle filenames as desired if
there's a space in a file's name unless it's wrapped in "'s.  I'll test
it against CVS tip and get back to you, but my experience has shown me
that at least one browser is chopping the filename at the first white
space character.

---
Kevin Benton
Perl/Bugzilla Developer/Administrator, Perforce SCM Administrator
AMD - ECSD Software Validation and Tools
 
The opinions stated in this communication do not necessarily reflect the
view of Advanced Micro Devices and have not been reviewed by management.
This communication may contain sensitive and/or confidential and/or
proprietary information.  Distribution of such information is strictly
prohibited without prior consent of Advanced Micro Devices.  This
communication is for the intended recipient(s) only.  If you have
received this communication in error, please notify the sender, then
destroy any remaining copies of this communication.





More information about the developers mailing list