diff options
author | James Moger <james.moger@gitblit.com> | 2015-02-11 10:15:47 -0500 |
---|---|---|
committer | James Moger <james.moger@gitblit.com> | 2015-02-11 10:15:47 -0500 |
commit | 5ec94c4282ed3630b7b4cd0fb5db62c20ce46d9d (patch) | |
tree | 99106c0053b5d1eb24e1a1f1b5e6b9f3a93e8212 | |
parent | ffe9423942a8a8c8f69d7b77c6a59e6435002d83 (diff) | |
parent | 38dbe7600e39731cc603e8adb211b81bd2fee2c0 (diff) | |
download | gitblit-5ec94c4282ed3630b7b4cd0fb5db62c20ce46d9d.tar.gz gitblit-5ec94c4282ed3630b7b4cd0fb5db62c20ce46d9d.zip |
Merge branch 'ticket/237' into develop
-rw-r--r-- | src/main/java/com/gitblit/manager/RepositoryManager.java | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/src/main/java/com/gitblit/manager/RepositoryManager.java b/src/main/java/com/gitblit/manager/RepositoryManager.java index 198a5d4b..c2c6088e 100644 --- a/src/main/java/com/gitblit/manager/RepositoryManager.java +++ b/src/main/java/com/gitblit/manager/RepositoryManager.java @@ -1921,12 +1921,14 @@ public class RepositoryManager implements IRepositoryManager { try { // issue-486/ticket-151: UTF-9 & UTF-18 + // issue-560/ticket-237: 'UTF8' Field field = RawParseUtils.class.getDeclaredField("encodingAliases"); field.setAccessible(true); Map<String, Charset> encodingAliases = (Map<String, Charset>) field.get(null); + encodingAliases.put("'utf8'", RawParseUtils.UTF8_CHARSET); encodingAliases.put("utf-9", RawParseUtils.UTF8_CHARSET); encodingAliases.put("utf-18", RawParseUtils.UTF8_CHARSET); - logger.info("Alias UTF-9 & UTF-18 encodings as UTF-8 in JGit"); + logger.info("Alias 'UTF8', UTF-9 & UTF-18 encodings as UTF-8 in JGit"); } catch (Throwable t) { logger.error("Failed to inject UTF-9 & UTF-18 encoding aliases into JGit", t); } |