master moved from b2b38820eace to 5de1cd36e710

2 new revisions:

Revision: 484605e748e2
Author:   Jean Deruelle <[email protected]>
Date:     Thu Feb 13 15:09:17 2014 UTC
Log:      Update Issue 257 fixing NPE spotted in TCK start...
http://code.google.com/p/sipservlets/source/detail?r=484605e748e2

Revision: 5de1cd36e710
Author:   Jean Deruelle <[email protected]>
Date:     Thu Feb 13 15:12:20 2014 UTC
Log:      Update Issue 257 Fixing NPE
http://code.google.com/p/sipservlets/source/detail?r=5de1cd36e710

==============================================================================
Revision: 484605e748e2
Author:   Jean Deruelle <[email protected]>
Date:     Thu Feb 13 15:09:17 2014 UTC
Log:      Update Issue 257 fixing NPE spotted in TCK start

(cherry picked from commit 47b6ea857285d091db92c68137d66eb80b3f1657)

http://code.google.com/p/sipservlets/source/detail?r=484605e748e2

Modified:
/containers/tomcat-7/src/main/java/org/mobicents/servlet/sip/startup/SipNamingContextListener.java

=======================================
--- /containers/tomcat-7/src/main/java/org/mobicents/servlet/sip/startup/SipNamingContextListener.java Tue Mar 27 15:02:55 2012 UTC +++ /containers/tomcat-7/src/main/java/org/mobicents/servlet/sip/startup/SipNamingContextListener.java Thu Feb 13 15:09:17 2014 UTC
@@ -90,14 +90,28 @@
logger.debug("Sip Subcontext removed from the JNDI context for container " + event.getContainer());
             }
         } if (type.equals(NAMING_CONTEXT_APPNAME_SUBCONTEXT_ADDED_EVENT)) {
-            addAppNameSubContext(envCtx, appName);
-            if(logger.isDebugEnabled()) {
- logger.debug(appName + " Subcontext added to the JNDI context for container " + event.getContainer());
+            if(appName != null) {
+ // https://code.google.com/p/sipservlets/issues/detail?id=257
+                addAppNameSubContext(envCtx, appName);
+                if(logger.isDebugEnabled()) {
+ logger.debug(appName + " Subcontext added to the JNDI context for container " + event.getContainer());
+                }
+            } else {
+                if(logger.isDebugEnabled()) {
+ logger.debug(appName + " is null so subcontext not added to JNDI context for container " + event.getContainer());
+                }
             }
} else if (type.equals(NAMING_CONTEXT_APPNAME_SUBCONTEXT_REMOVED_EVENT)) {
-            removeAppNameSubContext(envCtx, appName);
-            if(logger.isDebugEnabled()) {
- logger.debug(appName + " Subcontext removed from the JNDI context for container " + event.getContainer());
+            if(appName != null) {
+ // https://code.google.com/p/sipservlets/issues/detail?id=257
+                removeAppNameSubContext(envCtx, appName);
+                if(logger.isDebugEnabled()) {
+ logger.debug(appName + " Subcontext removed from the JNDI context for container " + event.getContainer());
+                }
+            } else {
+                if(logger.isDebugEnabled()) {
+ logger.debug(appName + " is null so subcontext not removed to JNDI context for container " + event.getContainer());
+                }
             }
         } else if (type.equals(NAMING_CONTEXT_SIP_FACTORY_ADDED_EVENT)) {
                        SipFactory sipFactory = (SipFactory) event.getData();

==============================================================================
Revision: 5de1cd36e710
Author:   Jean Deruelle <[email protected]>
Date:     Thu Feb 13 15:12:20 2014 UTC
Log:      Update Issue 257 Fixing NPE

http://code.google.com/p/sipservlets/source/detail?r=5de1cd36e710

Modified:
/containers/tomcat-7/src/main/java/org/mobicents/servlet/sip/startup/SipNamingContextListener.java

=======================================
--- /containers/tomcat-7/src/main/java/org/mobicents/servlet/sip/startup/SipNamingContextListener.java Thu Feb 13 15:09:17 2014 UTC +++ /containers/tomcat-7/src/main/java/org/mobicents/servlet/sip/startup/SipNamingContextListener.java Thu Feb 13 15:12:20 2014 UTC
@@ -1,18 +1,20 @@
 /*
- * This is free software; you can redistribute it and/or modify it
- * under the terms of the GNU Lesser General Public License as
- * published by the Free Software Foundation; either version 2.1 of
+ * TeleStax, Open Source Cloud Communications
+ * Copyright 2011-2014, Telestax Inc and individual contributors
+ * by the @authors tag.
+ *
+ * This program is free software: you can redistribute it and/or modify
+ * under the terms of the GNU Affero General Public License as
+ * published by the Free Software Foundation; either version 3 of
  * the License, or (at your option) any later version.
  *
- * This software is distributed in the hope that it will be useful,
+ * This program is distributed in the hope that it will be useful,
  * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * Lesser General Public License for more details.
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU Affero General Public License for more details.
  *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this software; if not, write to the Free
- * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
- * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ * You should have received a copy of the GNU Affero General Public License
+ * along with this program.  If not, see <http://www.gnu.org/licenses/>
  */
 package org.mobicents.servlet.sip.startup;

--

--- You received this message because you are subscribed to the Google Groups "mobicents-commits" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
For more options, visit https://groups.google.com/groups/opt_out.

Reply via email to