Skip to content

Commit

Permalink
!262 修复压缩包中,中文文件被编码问题
Browse files Browse the repository at this point in the history
Merge pull request !262 from 高雄/N/A
  • Loading branch information
klboke authored and gitee-org committed Dec 26, 2023
2 parents 8441d18 + 09f4400 commit bef81a9
Showing 1 changed file with 3 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -457,9 +457,12 @@ public FileAttribute getFileAttribute(String url, HttpServletRequest req) {
String _Path = urll.getPath(); //获取url路径
String urlStrr = getSubString(_Path, compressFileKey); //反代情况下添加前缀,只获取有压缩包字符的路径
originFileName = compressFileKey + urlStrr.trim(); //拼接完整路径
originFileName = URLDecoder.decode(originFileName, uriEncoding); //压缩包文件中文编码问题
attribute.setSkipDownLoad(true);
} catch (MalformedURLException e) {
e.printStackTrace();
} catch (UnsupportedEncodingException e) {
e.printStackTrace();
}
}
url = WebUtils.encodeUrlFileName(url);
Expand Down

0 comments on commit bef81a9

Please sign in to comment.