incubator-sling-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From jus...@apache.org
Subject svn commit: r1141352 - /sling/trunk/bundles/servlets/resolver/src/main/java/org/apache/sling/servlets/resolver/internal/SlingServletResolver.java
Date Thu, 30 Jun 2011 00:42:46 GMT
Author: justin
Date: Thu Jun 30 00:42:46 2011
New Revision: 1141352

URL: http://svn.apache.org/viewvc?rev=1141352&view=rev
Log:
SLING-2099 - fixing NPE in SlingServletResolver (thanks Alex for the patch)

Modified:
    sling/trunk/bundles/servlets/resolver/src/main/java/org/apache/sling/servlets/resolver/internal/SlingServletResolver.java

Modified: sling/trunk/bundles/servlets/resolver/src/main/java/org/apache/sling/servlets/resolver/internal/SlingServletResolver.java
URL: http://svn.apache.org/viewvc/sling/trunk/bundles/servlets/resolver/src/main/java/org/apache/sling/servlets/resolver/internal/SlingServletResolver.java?rev=1141352&r1=1141351&r2=1141352&view=diff
==============================================================================
--- sling/trunk/bundles/servlets/resolver/src/main/java/org/apache/sling/servlets/resolver/internal/SlingServletResolver.java
(original)
+++ sling/trunk/bundles/servlets/resolver/src/main/java/org/apache/sling/servlets/resolver/internal/SlingServletResolver.java
Thu Jun 30 00:42:46 2011
@@ -368,7 +368,7 @@ public class SlingServletResolver implem
             final NamedScriptResourceCollector locationUtil = NamedScriptResourceCollector.create(scriptName,
resource, this.executionPaths);
             servlet = getServlet(locationUtil, null, resolver);
 
-            if (log.isDebugEnabled()) {
+            if (log.isDebugEnabled() && servlet != null) {
                 log.debug("resolveServlet returns servlet {}", RequestUtil.getServletName(servlet));
             }
         }



Mime
View raw message