Details
-
Bug
-
Status: Closed
-
Blocker
-
Resolution: Fixed
-
None
-
None
-
blocker
-
P2
-
49332
Description
The Type.getReturnTypeSize() method doesn't decode Type.getTypeSize() output.
The same bug was present in FieldInstruction.getFieldSize(), filed and fixed as BCEL-138 https://issues.apache.org/bugzilla/show_bug.cgi?id=48280
As a result of this bug, the BCEL calculates the wrong size of the return type for methods, leading to FindBugs going off the rails.
The fix is the same as to fix FieldInstruction.getFieldSize(): use Type.size() to decode the coded value.
I've attached a patch with the fix, and I've also looked at the other uses of getTypeSize(), and all the other invocations seem OK.