tomee-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From dblev...@apache.org
Subject svn commit: r659208 - in /openejb/trunk/openejb3/container/openejb-core/src/main/java/org/apache/openejb: assembler/DeployerEjb.java core/stateful/StatefulInstanceManager.java
Date Thu, 22 May 2008 19:07:15 GMT
Author: dblevins
Date: Thu May 22 12:07:13 2008
New Revision: 659208

URL: http://svn.apache.org/viewvc?rev=659208&view=rev
Log:
Removed more potentially unsafe throwable to exception casts

Modified:
    openejb/trunk/openejb3/container/openejb-core/src/main/java/org/apache/openejb/assembler/DeployerEjb.java
    openejb/trunk/openejb3/container/openejb-core/src/main/java/org/apache/openejb/core/stateful/StatefulInstanceManager.java

Modified: openejb/trunk/openejb3/container/openejb-core/src/main/java/org/apache/openejb/assembler/DeployerEjb.java
URL: http://svn.apache.org/viewvc/openejb/trunk/openejb3/container/openejb-core/src/main/java/org/apache/openejb/assembler/DeployerEjb.java?rev=659208&r1=659207&r2=659208&view=diff
==============================================================================
--- openejb/trunk/openejb3/container/openejb-core/src/main/java/org/apache/openejb/assembler/DeployerEjb.java
(original)
+++ openejb/trunk/openejb3/container/openejb-core/src/main/java/org/apache/openejb/assembler/DeployerEjb.java
Thu May 22 12:07:13 2008
@@ -155,9 +155,6 @@
             if (e instanceof OpenEJBException) {
                 throw (OpenEJBException) e;
             }
-            if (e instanceof Error) {
-                throw (OpenEJBException) e;
-            }
             throw new OpenEJBException(e);
         }
     }

Modified: openejb/trunk/openejb3/container/openejb-core/src/main/java/org/apache/openejb/core/stateful/StatefulInstanceManager.java
URL: http://svn.apache.org/viewvc/openejb/trunk/openejb3/container/openejb-core/src/main/java/org/apache/openejb/core/stateful/StatefulInstanceManager.java?rev=659208&r1=659207&r2=659208&view=diff
==============================================================================
--- openejb/trunk/openejb3/container/openejb-core/src/main/java/org/apache/openejb/core/stateful/StatefulInstanceManager.java
(original)
+++ openejb/trunk/openejb3/container/openejb-core/src/main/java/org/apache/openejb/core/stateful/StatefulInstanceManager.java
Thu May 22 12:07:13 2008
@@ -543,9 +543,11 @@
             return new InvalidateReferenceException(new TransactionRolledbackException(t));
         } else if (t instanceof RemoteException) {
             return new InvalidateReferenceException(t);
-        } else {
+        } else if (t instanceof EJBException) {
             EJBException e = (EJBException) t;
             return new InvalidateReferenceException(new RemoteException(e.getMessage(), e.getCausedByException()));
+        } else {
+            return new InvalidateReferenceException(new RemoteException().initCause(t));
         }
 
     }



Mime
View raw message