geronimo-scm mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From rickmcgu...@apache.org
Subject svn commit: r545246 - /geronimo/server/trunk/modules/geronimo-corba/src/main/java/org/apache/geronimo/corba/StandardServant.java
Date Thu, 07 Jun 2007 17:34:50 GMT
Author: rickmcguire
Date: Thu Jun  7 10:34:49 2007
New Revision: 545246

URL: http://svn.apache.org/viewvc?view=rev&rev=545246
Log:
GERONIMO-3226 NPE when attempting to export an EJB without a home or remote interface via
CORBA.


Modified:
    geronimo/server/trunk/modules/geronimo-corba/src/main/java/org/apache/geronimo/corba/StandardServant.java

Modified: geronimo/server/trunk/modules/geronimo-corba/src/main/java/org/apache/geronimo/corba/StandardServant.java
URL: http://svn.apache.org/viewvc/geronimo/server/trunk/modules/geronimo-corba/src/main/java/org/apache/geronimo/corba/StandardServant.java?view=diff&rev=545246&r1=545245&r2=545246
==============================================================================
--- geronimo/server/trunk/modules/geronimo-corba/src/main/java/org/apache/geronimo/corba/StandardServant.java
(original)
+++ geronimo/server/trunk/modules/geronimo-corba/src/main/java/org/apache/geronimo/corba/StandardServant.java
Thu Jun  7 10:34:49 2007
@@ -100,8 +100,14 @@
         Class type;
         if (InterfaceType.EJB_HOME == ejbInterfaceType) {
             type = ejbDeployment.getHomeInterface();
+            if (type == null) {
+                throw new IllegalArgumentException("EJB " + ejbDeployment.getEjbName() +
" does not have a home interface");
+            }
         } else if (InterfaceType.EJB_OBJECT == ejbInterfaceType) {
             type = ejbDeployment.getRemoteInterface();
+            if (type == null) {
+                throw new IllegalArgumentException("EJB " + ejbDeployment.getEjbName() +
" does not have a remote interface");
+            }
         } else {
             throw new IllegalArgumentException("Only home and remote interfaces are supported
in this servant: " + ejbInterfaceType);
         }



Mime
View raw message