Skip to content

Commit

Permalink
Fixes Non-ASCII characters are not saved correctly in JVM options add…
Browse files Browse the repository at this point in the history
…ed using the JVM Options page

Signed-off-by: kaido207 <kaido.hiroki@fujitsu.com>
  • Loading branch information
kaido207 committed Feb 9, 2024
1 parent 418e007 commit 88340dc
Showing 1 changed file with 2 additions and 13 deletions.
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
/*
* Copyright (c) 2024 Contributors to the Eclipse Foundation.
* Copyright (c) 1997, 2018 Oracle and/or its affiliates. All rights reserved.
*
* This program and the accompanying materials are made available under the
Expand Down Expand Up @@ -1094,19 +1095,7 @@ public static String escapePropertyValue(String str){
builder.append(ch);
break;
default:
// Check if we should unicode escape this...
if ((ch > 0x7e) || (ch < 0x20)) {
builder.append("\\u");
chStr = Integer.toHexString(ch);
len = chStr.length();
for (int idx=4; idx > len; idx--) {
// Add leading 0's
builder.append('0');
}
builder.append(chStr);
} else {
builder.append(ch);
}
builder.append(ch);
break;
}
ch = it.next();
Expand Down

0 comments on commit 88340dc

Please sign in to comment.