Defensive String equals comparison in ClassReader
Issue: SPR-12382
This commit is contained in:
@@ -928,7 +928,8 @@ public class ClassReader {
|
||||
*/
|
||||
if (WRITER && mv instanceof MethodWriter) {
|
||||
MethodWriter mw = (MethodWriter) mv;
|
||||
if (mw.cw.cr == this && signature == mw.signature) {
|
||||
if (mw.cw.cr == this &&
|
||||
(signature != null ? signature.equals(mw.signature) : mw.signature == null)) {
|
||||
boolean sameExceptions = false;
|
||||
if (exceptions == null) {
|
||||
sameExceptions = mw.exceptionCount == 0;
|
||||
|
||||
Reference in New Issue
Block a user