-
Bug
-
Resolution: Fixed
-
P4
-
8, 9
Issue | Fix Version | Assignee | Priority | Status | Resolution | Resolved In Build |
---|---|---|---|---|---|---|
JDK-8083501 | emb-9 | Unassigned | P4 | Resolved | Fixed | team |
JDK-8342981 | openjdk8u442 | Chen Liang | P4 | Resolved | Fixed | b01 |
"If the value of the name_index item is zero, then this parameters element indicates a formal parameter with no name. "
But j.l.r.Executable.getParameters() throw MalformedParameterExeption: Invalid parameter name "".
This looks as if parameter had empty-string name.
It is reproduced on Solaris with 8, 8u26, 9 and 9.0
and on Windows 7 with 8u20.
Minimized test:
------------------------------------------------------------
public class Second {
public static String method(int i){
return "in";
}
public static void main(String[] args) throws NoSuchMethodException {
Second.class.getMethod("method", int.class).getParameters();
}
}
------------------------------------------------------------
After compilation (javac -parameters Second.java) MethodParameters attribute of "method" was changed from "0x0100110000;" to "0x0100000000;". Modified version is attached.
The following JCK test will fail due to this bug: vm/classfmt/atr/atrmtp003/atrmtp00303m1/atrmtp00303m1.
- backported by
-
JDK-8083501 Zero name_index item of MethodParameters attribute cause MalformedParameterException.
-
- Resolved
-
-
JDK-8342981 Zero name_index item of MethodParameters attribute cause MalformedParameterException.
-
- Resolved
-
- blocks
-
JDK-8062556 Add jdk tests for JDK-8058322 and JDK-8058313
-
- Closed
-
- duplicates
-
JDK-8341145 MalformedParametersException when using reflection on an inner class constructor
-
- Closed
-
-
JDK-8170063 Jdk incorrectly process nameless parameters in MethodParameters Attribute
-
- Closed
-
- links to
-
Commit(master) openjdk/jdk8u-dev/b6616d68
-
Review(master) openjdk/jdk8u-dev/592
-
Review(master) openjdk/jdk8u/63