修复编码错误

This commit is contained in:
648540858
2020-10-16 09:50:19 +08:00
parent b15115565c
commit a7f224b1af
3 changed files with 19 additions and 19 deletions

View File

@@ -362,7 +362,7 @@ public class MessageRequestProcessor extends SIPRequestAbstractProcessor {
private Element getRootElement(RequestEvent evt) throws DocumentException {
Request request = evt.getRequest();
SAXReader reader = new SAXReader();
// reader.setEncoding("GB2312");
reader.setEncoding("gbk");
Document xml = reader.read(new ByteArrayInputStream(request.getRawContent()));
return xml.getRootElement();
}