mirror of
https://github.com/overcuriousity/autopsy-flatpak.git
synced 2025-07-19 19:14:55 +00:00
Merge pull request #387 from jawallace/hex_viewer
Fix string out of bounds exception on non-windows.
This commit is contained in:
commit
40e55a4f64
@ -102,10 +102,10 @@ public class DataConversion {
|
||||
outputStringBuilder.append(" ");
|
||||
|
||||
// print the ascii columns
|
||||
String ascii = new String(array, curOffset, lineLen);
|
||||
String ascii = new String(array, curOffset, lineLen, java.nio.charset.StandardCharsets.US_ASCII);
|
||||
for (int i = 0; i < 16; i++) {
|
||||
char c = ' ';
|
||||
if (i < lineLen) {
|
||||
if (i < ascii.length()) {
|
||||
c = ascii.charAt(i);
|
||||
int dec = (int) c;
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user