On Wed, 23 Jun 2021 17:20:27 GMT, Alexander Zuev <kiz...@openjdk.org> wrote:
> 8268775: Password is being converted to String in AccessibleJPasswordField There's code but not a single word of description of the fix. What is the problem, what are the changes here, why do they fix it, and what are the risks / consequences and why is there no test ? It is not very kind to reviewers to offer no explanation. src/java.desktop/share/classes/javax/swing/JPasswordField.java line 514: > 512: public String getAtIndex(int part, int index) { > 513: if (part == AccessibleText.CHARACTER) { > 514: return getEchoString(super.getAtIndex(part, index)); I don't see how removing the local variable changes anything. Explanation ?? src/java.desktop/share/classes/javax/swing/JPasswordField.java line 546: > 544: public String getAfterIndex(int part, int index) { > 545: if (part == AccessibleText.CHARACTER) { > 546: return getEchoString(super.getAfterIndex(part, index)); I don't see how removing the local variable changes anything. Explanation ?? ------------- PR: https://git.openjdk.java.net/jdk17/pull/127