We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 8f46494 commit 684be71Copy full SHA for 684be71
pg/src/test/java/org/bouncycastle/test/DumpUtil.java
@@ -1,5 +1,6 @@
1
package org.bouncycastle.test;
2
3
+import org.bouncycastle.util.Pack;
4
import org.bouncycastle.util.encoders.Hex;
5
6
public class DumpUtil
@@ -43,10 +44,13 @@ public static String hexdump(int startIndent, byte[] array)
43
44
45
StringBuilder out = new StringBuilder();
46
int l = 0;
47
+ byte[] counterLabel = new byte[4];
48
+
49
while (l < octets.length)
50
{
51
// index row
- out.append(String.format("%08X", l)).append(" ");
52
+ Pack.intToBigEndian(l, counterLabel, 0);
53
+ out.append(Hex.toHexString(counterLabel)).append(" ");
54
// first 8 octets of a line
55
for (int i = l ; i < l + 8 && i < octets.length; i++)
56
0 commit comments