Merge pull request #324 from FlXME/patch-1

Performance issue when building strings
This commit is contained in:
skylot
2018-07-30 11:34:23 +03:00
committed by GitHub
@@ -193,7 +193,7 @@ public class CertificateManager {
char[] hexDigits = {'0', '1', '2', '3', '4', '5', '6', '7', '8', '9',
'A', 'B', 'C', 'D', 'E', 'F'};
StringBuffer buf = new StringBuffer(bytes.length * 3);
StringBuilder buf = new StringBuilder(bytes.length * 3);
for (int i = 0; i < bytes.length; ++i) {
buf.append(hexDigits[(bytes[i] & 0xf0) >> 4]);