Bug 153693

Summary: konqueror offers wrong name for file to save, based on content-disposition
Product: [Applications] konqueror Reporter: kavol <kavol>
Component: generalAssignee: Konqueror Developers <konq-bugs>
Status: RESOLVED FIXED    
Severity: normal    
Priority: NOR    
Version: unspecified   
Target Milestone: ---   
Platform: Compiled Sources   
OS: Linux   
Latest Commit: Version Fixed In:

Description kavol 2007-12-08 20:53:21 UTC
Version:            (using KDE Devel)
Installed from:    Compiled sources
Compiler:          gcc (GCC) 4.1.2 (Gentoo 4.1.2 p1.0.1) 
OS:                Linux

when trying to save a bugzilla attachment from http://bugs.gentoo.org/attachment.cgi?id=136498 the file name offered by Konqueror was:
="qmmp-0.1.4.ebuild"
i.e. including the equals sign and quotation marks, which should not be there

this comes from this http header:
Content-disposition: inline; filename="qmmp-0.1.4.ebuild"

there are several bugreports related to saving files or content-disposition, but nothing exactly like this (especially against KDE4 branch)

using the provided link, I can 100% reproduce the problem using the recent Konqueror version:
$ konqueror --version
Qt: 4.3.2
KDE: 3.97.1 (KDE 4.0 >= 20071206)
Konqueror: 3.97.1 (KDE 4.0 >= 20071206)
Comment 1 Maksim Orlovich 2008-01-10 18:43:12 UTC
SVN commit 759470 by orlovich:

Parse content-disposition better; at the very least not including the =, ", and last ".
Also makes a likely ill-advised attempt to do it following the spec, which at least 
should make it more tolerant to LWS
BUG:153693
CCBUG:155276


 M  +82 -17    http.cpp  


WebSVN link: http://websvn.kde.org/?view=rev&revision=759470