Skip to content
Permalink
Browse files
[CXF-5368] Check for both filename and name in Content-Disposition
git-svn-id: https://svn.apache.org/repos/asf/cxf/trunk@1541141 13f79535-47bb-0310-9956-ffa450edef68
  • Loading branch information
dkulp committed Nov 12, 2013
1 parent b5c38cc commit c1674905a6deea5f7281f636039b9e5382187828
Showing 1 changed file with 6 additions and 1 deletion.
@@ -348,7 +348,12 @@ static String getContentDispositionFileName(String cd) {
return null;
}
//TODO: save ContentDisposition directly
return new ContentDisposition(cd).getParameter("filename");
ContentDisposition c = new ContentDisposition(cd);
String s = c.getParameter("filename");
if (s == null) {
s = c.getParameter("name");
}
return s;
}

public static InputStream decode(InputStream in, String encoding) throws IOException {

0 comments on commit c167490

Please sign in to comment.