mirror of
https://github.com/DSpace/DSpace.git
synced 2025-10-17 23:13:10 +00:00
[DS-2196] License files do not support UTF-8 characters
This commit is contained in:
@@ -129,7 +129,7 @@ public class LicenseUtils
|
||||
// + DCDate.getCurrent().toString() + " (GMT):\n\n" + license;
|
||||
|
||||
// Store text as a bitstream
|
||||
byte[] licenseBytes = licenseText.getBytes();
|
||||
byte[] licenseBytes = licenseText.getBytes("UTF-8");
|
||||
ByteArrayInputStream bais = new ByteArrayInputStream(licenseBytes);
|
||||
Bitstream b = item.createSingleBitstream(bais, "LICENSE");
|
||||
|
||||
|
@@ -99,7 +99,7 @@ public class SimpleHTMLFragment extends AbstractWingElement {
|
||||
String xml = "<fragment>" + fragment + "</fragment>";
|
||||
|
||||
ByteArrayInputStream inputStream = new ByteArrayInputStream(xml
|
||||
.getBytes());
|
||||
.getBytes("UTF-8"));
|
||||
|
||||
SAXBuilder builder = new SAXBuilder();
|
||||
Document document = builder.build(inputStream);
|
||||
|
Reference in New Issue
Block a user