User: schaefera Date: 01/11/01 22:17:06 Modified: src/main/org/jboss/verifier/strategy Tag: Branch_2_4 AbstractVerifier.java Log: Fixes for bug #441291 and #434739. Revision Changes Path No revision No revision 1.18.4.2 +19 -6 jboss/src/main/org/jboss/verifier/strategy/AbstractVerifier.java Index: AbstractVerifier.java =================================================================== RCS file: /cvsroot/jboss/jboss/src/main/org/jboss/verifier/strategy/AbstractVerifier.java,v retrieving revision 1.18.4.1 retrieving revision 1.18.4.2 diff -u -r1.18.4.1 -r1.18.4.2 --- AbstractVerifier.java 2001/10/29 13:26:12 1.18.4.1 +++ AbstractVerifier.java 2001/11/02 06:17:06 1.18.4.2 @@ -19,7 +19,7 @@ * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA * * This package and its source code is available at www.jboss.org - * $Id: AbstractVerifier.java,v 1.18.4.1 2001/10/29 13:26:12 negaton Exp $ + * $Id: AbstractVerifier.java,v 1.18.4.2 2001/11/02 06:17:06 schaefera Exp $ */ // standard imports @@ -61,8 +61,16 @@ * @author Juha Lindfors ([EMAIL PROTECTED]) * @author Aaron Mulder ([EMAIL PROTECTED]) * @author Vinay Menon ([EMAIL PROTECTED]) + * @author <a href="mailto:[EMAIL PROTECTED]">Andreas Schaefer</a> * - * @version $Revision: 1.18.4.1 $ + * <p><b>Revisions:</b></p> + * <p><b>20011101: Andy</b> + * <ul> + * <li>Changed the throwRemoteException() method to check accordingly to the RMI spec.</li> + * </ul> + * </p> + * + * @version $Revision: 1.18.4.2 $ * @since JDK 1.3 */ public abstract class AbstractVerifier implements VerificationStrategy { @@ -178,11 +186,16 @@ public boolean throwsRemoteException(Method method) { Class[] exception = method.getExceptionTypes(); - - for (int i = 0; i < exception.length; ++i) - if (java.rmi.RemoteException.class.isAssignableFrom(exception[i])) - return true; + for (int i = 0; i < exception.length; ++i) { +// Not true see bug report #434739 +// if (java.rmi.RemoteException.class.isAssignableFrom(exception[i])) +// According to the RMI spec. a remote interface must throw an RemoteException +// or any of its super classes therefore the check must be done vice versa + if( exception[ i ].isAssignableFrom( java.rmi.RemoteException.class ) ) { + return true; + } + } return false; }
_______________________________________________ Jboss-development mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/jboss-development