ASM ClassReader leniently handles label offset mismatch (again)

Issue: SPR-17467
This commit is contained in:
Juergen Hoeller 2018-11-05 17:44:23 +01:00
parent a3cd7af72d
commit 2ac4355ec0
1 changed files with 5 additions and 0 deletions

View File

@ -2437,6 +2437,11 @@ public class ClassReader {
* @return a non null Label, which must be equal to labels[bytecodeOffset].
*/
protected Label readLabel(final int bytecodeOffset, final Label[] labels) {
// SPRING PATCH: leniently handle offset mismatch
if (bytecodeOffset >= labels.length) {
return new Label();
}
// END OF PATCH
if (labels[bytecodeOffset] == null) {
labels[bytecodeOffset] = new Label();
}