This patch fixes RefernceType.Methods to work with interfaces.
Currently, since the ReferenceTypeId is immediately cast to a
ClassReferenceTypeId, Interfaces will cause problems with this method.
This patch changes this so a generic ReferenceTypeId is used, which
avoid the issue without changing the functionality.
ChangeLog
2007-05-11 Kyle Galloway <[EMAIL PROTECTED]>
* gnu/classpath/jdwp/processor/ReferenceTypeCommandSet
(executeMethods): Remove cast to ClassReferenceTypeId.
Questions/Issues?
Thanks,
Kyle
Index: gnu/classpath/jdwp/processor/ReferenceTypeCommandSet.java
===================================================================
RCS file: /sources/classpath/classpath/gnu/classpath/jdwp/processor/ReferenceTypeCommandSet.java,v
retrieving revision 1.10
diff -u -r1.10 ReferenceTypeCommandSet.java
--- gnu/classpath/jdwp/processor/ReferenceTypeCommandSet.java 9 Mar 2007 21:23:10 -0000 1.10
+++ gnu/classpath/jdwp/processor/ReferenceTypeCommandSet.java 11 May 2007 18:43:25 -0000
@@ -183,8 +183,7 @@
private void executeMethods(ByteBuffer bb, DataOutputStream os)
throws JdwpException, IOException
{
- ClassReferenceTypeId refId
- = (ClassReferenceTypeId) idMan.readReferenceTypeId(bb);
+ ReferenceTypeId refId = idMan.readReferenceTypeId(bb);
Class clazz = refId.getType();
VMMethod[] methods = VMVirtualMachine.getAllClassMethods(clazz);