Duplicate :
|
Name: rmT116609 Date: 02/12/2003 FULL PRODUCT VERSION : # java -version java version "1.4.1_01" Java(TM) 2 Runtime Environment, Standard Edition (build 1.4.1_01-b01) Java HotSpot(TM) Client VM (build 1.4.1_01-b01, mixed mode) FULL OPERATING SYSTEM VERSION : Linux 2.4.18-24.7.x i686 Additional Operating Systems: Solaris 2.8 DESCRIPTION OF THE PROBLEM : If you disassemble class files with javap from 1.4.x you will sometimes get "null" as the receiver of invocations and field operations. This is a bug in that version of javap. If you use jdk-sun-1.3.1 it works just fine. The bug seems to have infested IBM, SUN and blackdown's JDK 1.4.x. STEPS TO FOLLOW TO REPRODUCE THE PROBLEM : 1. javap -c java.util.Vector | grep null EXPECTED VERSUS ACTUAL BEHAVIOR : Actual result (you can guess what I'd expect): javap -c java.util.Vector | grep null 2 getfield #26 <Field null> 7 putfield #26 <Field null> 2 getfield #27 <Field null> 7 putfield #27 <Field null> 2 getfield #29 <Field null> 7 putfield #29 <Field null> 36 aconst_null 1 ifnonnull 34 15 ifnonnull 20 43 ifnonnull 72 57 ifnonnull 62 2 getfield #43 <Field null> 7 putfield #43 <Field null> 112 aconst_null 2 getfield #45 <Field null> 7 putfield #45 <Field null> 2 getfield #47 <Field null> 7 putfield #47 <Field null> 2 getfield #48 <Field null> 7 putfield #48 <Field null> 2 getfield #51 <Field null> 7 putfield #51 <Field null> 20 aconst_null 38 putfield #54 <Field null> 55 aconst_null 2 getfield #62 <Field null> 7 putfield #62 <Field null> 2 getfield #65 <Field null> 7 putfield #65 <Field null> 78 aconst_null 2 invokespecial #67 <Method null> 2 getfield #68 <Field null> 7 putfield #68 <Field null> 2 invokespecial #71 <Method null> 2 invokespecial #72 <Method null> 2 getfield #73 <Field null> 7 putfield #73 <Field null> 1 invokespecial #76 <Method null> 2 getfield #79 <Field null> 7 putfield #79 <Field null> With JDK1.3.1_07: ------------------ java version "1.3.1_07" Java(TM) 2 Runtime Environment, Standard Edition (build 1.3.1_07-b02) Java HotSpot(TM) Client VM (build 1.3.1_07-b02, mixed mode) cindercone:/home/ranjithm/tmpjava 46 % javap -c java.util.Vector | grep null 36 aconst_null 1 ifnonnull 34 15 ifnonnull 20 43 ifnonnull 72 57 ifnonnull 62 112 aconst_null 10 aconst_null 55 aconst_null 78 aconst_null 59 aconst_null REPRODUCIBILITY : This bug can be reproduced always. CUSTOMER WORKAROUND : Switch to C and use gdb. Release Regression From : 1.3.1_07 The above release value was the last known release where this bug was known to work. Since then there has been a regression. (Review ID: 181152) ======================================================================