-
Bug
-
Resolution: Fixed
-
P4
-
5.0, 6, 6u1, 6u2
-
b07
-
generic
-
generic
-
Verified
Issue | Fix Version | Assignee | Priority | Status | Resolution | Resolved In Build |
---|---|---|---|---|---|---|
JDK-2147968 | 6u2 | Poonam Bajaj Parhar | P3 | Closed | Won't Fix |
Name: ipR10196 Date: 02/17/2004
--------------------------------------
Test : nsk/sajdi/ClassType/interfaces/interfaces001
VM : ClientVM, ServerVM
Mode : all
Platform : generic
OS : generic
JDK : 1.5.0 b32-b38
----------------------------------------
This SA-JDI test checks if method ClassType.allInterfaces()
returns list af all implemented interfaces including ones
inherited from superclass.
Here is fragment of classes hierarchy:
TestedClass
extends SuperClass
inplements Interface4
extends SuperInterface4
extends SuperSuperClass
implements SuperInterface4
TestedClass inherits SuperInterface4 by two different ways:
from its direct superclass (SuperClass) and indirect superclass
(SuperSuperClass). In this case allInterfaces() returns two
instances of SuperInterface4.
This bug was revealed for SA-JDI connectors, but it is also
reproduced with legacy JDI connectors.
This test will be available in the next r27 testbase release.
To reproduce this failure:
cd /net/jano.sfbay/export/disk20/GammaBase/Bugs/<this bug number>
sh build.sh $JAVA_HOME
sh run.sh [-pid | -core | -socket] [-g] [-v] $JAVA_HOME [JAVA_OPTS]
where:
-pid - run test with SA-JDI pid attaching connector (default)
-core - run test with SA-JDI core attaching connector
-socket - run test with JDI socket attaching connector
-g - run test with java_g binaries
-v - run test in verbose mode
Here is fragment of the test output:
------------------------------------------------------------------
Check allInterfaces():
<...>
type #7
type name: nsk.sajdi.ClassType.interfaces.interfaces001aSuperInterface4
signature:
Lnsk/sajdi/ClassType/interfaces/interfaces001aSuperInterface4;
modifiers: 0x600
isSynthetic: false
hash code: -195713568
class loader: instance of sun.misc.Launcher$AppClassLoader(id=0)
class object: instance of java.lang.Class(reflected class=
nsk.sajdi.ClassType.interfaces.interfaces001aSuperInterface4,
id=10)
def statum: Java
avail strata: [Java]
source name: interfaces001aTestedClass.java
source names: [interfaces001aTestedClass.java]
source paths:
[nsk/sajdi/ClassType/interfaces/interfaces001aTestedClass.java]
... found checked type #3
check classesByName():
found type: interface
nsk.sajdi.ClassType.interfaces.interfaces001aSuperInterface4
(loaded by instance of
sun.misc.Launcher$AppClassLoader(id=0))
equals: true
compareTo: 0
hash code: -195713568
equals: true
type #8
type name: nsk.sajdi.ClassType.interfaces.interfaces001aSuperInterface4
signature:
Lnsk/sajdi/ClassType/interfaces/interfaces001aSuperInterface4;
modifiers: 0x600
isSynthetic: false
hash code: -195713568
class loader: instance of sun.misc.Launcher$AppClassLoader(id=0)
class object: instance of java.lang.Class(reflected class=
nsk.sajdi.ClassType.interfaces.interfaces001aSuperInterface4,
id=10)
def statum: Java
avail strata: [Java]
source name: interfaces001aTestedClass.java
source names: [interfaces001aTestedClass.java]
source paths:
[nsk/sajdi/ClassType/interfaces/interfaces001aTestedClass.java]
... found checked type #3
check classesByName():
found type: interface
nsk.sajdi.ClassType.interfaces.interfaces001aSuperInterface4
(loaded by instance of
sun.misc.Launcher$AppClassLoader(id=0))
equals: true
compareTo: 0
hash code: -195713568
equals: true
<...>
Check if all expected types found
# ERROR: Tested methods returned duplicated type:
# ERROR: short name: SuperInterface4
# ERROR: signature:
Lnsk/sajdi/ClassType/interfaces/interfaces001aSuperInterface4;
# ERROR: found count: 2
------------------------------------------------------------------
======================================================================
--------------------------------------
Test : nsk/sajdi/ClassType/interfaces/interfaces001
VM : ClientVM, ServerVM
Mode : all
Platform : generic
OS : generic
JDK : 1.5.0 b32-b38
----------------------------------------
This SA-JDI test checks if method ClassType.allInterfaces()
returns list af all implemented interfaces including ones
inherited from superclass.
Here is fragment of classes hierarchy:
TestedClass
extends SuperClass
inplements Interface4
extends SuperInterface4
extends SuperSuperClass
implements SuperInterface4
TestedClass inherits SuperInterface4 by two different ways:
from its direct superclass (SuperClass) and indirect superclass
(SuperSuperClass). In this case allInterfaces() returns two
instances of SuperInterface4.
This bug was revealed for SA-JDI connectors, but it is also
reproduced with legacy JDI connectors.
This test will be available in the next r27 testbase release.
To reproduce this failure:
cd /net/jano.sfbay/export/disk20/GammaBase/Bugs/<this bug number>
sh build.sh $JAVA_HOME
sh run.sh [-pid | -core | -socket] [-g] [-v] $JAVA_HOME [JAVA_OPTS]
where:
-pid - run test with SA-JDI pid attaching connector (default)
-core - run test with SA-JDI core attaching connector
-socket - run test with JDI socket attaching connector
-g - run test with java_g binaries
-v - run test in verbose mode
Here is fragment of the test output:
------------------------------------------------------------------
Check allInterfaces():
<...>
type #7
type name: nsk.sajdi.ClassType.interfaces.interfaces001aSuperInterface4
signature:
Lnsk/sajdi/ClassType/interfaces/interfaces001aSuperInterface4;
modifiers: 0x600
isSynthetic: false
hash code: -195713568
class loader: instance of sun.misc.Launcher$AppClassLoader(id=0)
class object: instance of java.lang.Class(reflected class=
nsk.sajdi.ClassType.interfaces.interfaces001aSuperInterface4,
id=10)
def statum: Java
avail strata: [Java]
source name: interfaces001aTestedClass.java
source names: [interfaces001aTestedClass.java]
source paths:
[nsk/sajdi/ClassType/interfaces/interfaces001aTestedClass.java]
... found checked type #3
check classesByName():
found type: interface
nsk.sajdi.ClassType.interfaces.interfaces001aSuperInterface4
(loaded by instance of
sun.misc.Launcher$AppClassLoader(id=0))
equals: true
compareTo: 0
hash code: -195713568
equals: true
type #8
type name: nsk.sajdi.ClassType.interfaces.interfaces001aSuperInterface4
signature:
Lnsk/sajdi/ClassType/interfaces/interfaces001aSuperInterface4;
modifiers: 0x600
isSynthetic: false
hash code: -195713568
class loader: instance of sun.misc.Launcher$AppClassLoader(id=0)
class object: instance of java.lang.Class(reflected class=
nsk.sajdi.ClassType.interfaces.interfaces001aSuperInterface4,
id=10)
def statum: Java
avail strata: [Java]
source name: interfaces001aTestedClass.java
source names: [interfaces001aTestedClass.java]
source paths:
[nsk/sajdi/ClassType/interfaces/interfaces001aTestedClass.java]
... found checked type #3
check classesByName():
found type: interface
nsk.sajdi.ClassType.interfaces.interfaces001aSuperInterface4
(loaded by instance of
sun.misc.Launcher$AppClassLoader(id=0))
equals: true
compareTo: 0
hash code: -195713568
equals: true
<...>
Check if all expected types found
# ERROR: Tested methods returned duplicated type:
# ERROR: short name: SuperInterface4
# ERROR: signature:
Lnsk/sajdi/ClassType/interfaces/interfaces001aSuperInterface4;
# ERROR: found count: 2
------------------------------------------------------------------
======================================================================
- backported by
-
JDK-2147968 SA-JDI: ClassType.allInterfaces() returns inherited interface twice
- Closed