[tor-commits] [metrics-lib/release] Remove redundant string operation.
karsten at torproject.org
karsten at torproject.org
Wed Sep 26 15:13:24 UTC 2018
commit a1b07be29685426e13911771b45210f0f6ae33e0
Author: Karsten Loesing <karsten.loesing at gmx.net>
Date: Tue Aug 21 12:07:50 2018 +0200
Remove redundant string operation.
---
src/main/java/org/torproject/descriptor/impl/RelayDirectoryImpl.java | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/src/main/java/org/torproject/descriptor/impl/RelayDirectoryImpl.java b/src/main/java/org/torproject/descriptor/impl/RelayDirectoryImpl.java
index 5eb5b6f..6370e87 100644
--- a/src/main/java/org/torproject/descriptor/impl/RelayDirectoryImpl.java
+++ b/src/main/java/org/torproject/descriptor/impl/RelayDirectoryImpl.java
@@ -264,7 +264,7 @@ public class RelayDirectoryImpl extends DescriptorImpl
sb.append("-----BEGIN RSA PUBLIC KEY-----\n");
String keyString = partsNoOpt[1];
while (keyString.length() > 64) {
- sb.append(keyString.substring(0, 64)).append(NL);
+ sb.append(keyString, 0, 64).append(NL);
keyString = keyString.substring(64);
}
if (keyString.length() > 0) {
More information about the tor-commits
mailing list