Uploaded image for project: 'logback'
  1. logback
  2. LOGBACK-443

LoggerContext.getLogger(final String name) doesn't check if name is null

    Details

    • Type: Bug
    • Status: Resolved
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: 0.9.12
    • Component/s: logback-classic
    • Labels:
      None
    • Environment:

      Operating System: All
      Platform: All

    • Bugzilla Id:
      146

      Description

      hence loggerCache.get(name) could fail (NPE) in line 117:

      java.lang.NullPointerException
      at java.util.Hashtable.get(Hashtable.java:336)
      at ch.qos.logback.classic.LoggerContext.getLogger(LoggerContext.java:117)
      at ch.qos.logback.classic.LoggerContext.getLogger(LoggerContext.java:44)
      at org.slf4j.LoggerFactory.getLogger(LoggerFactory.java:88)
      at org.apache.sling.osgi.log.LogSupport.getLogger(LogSupport.java:322)
      at org.apache.sling.osgi.log.LogSupport.logOut(LogSupport.java:333)
      at org.apache.sling.osgi.log.LogSupport.fireLogEvent(LogSupport.java:167)
      at org.apache.sling.osgi.log.LogSupport.bundleChanged(LogSupport.java:216)
      at org.apache.felix.framework.util.EventDispatcher.invokeBundleListenerCallback(EventDispatcher.java:690)
      at org.apache.felix.framework.util.EventDispatcher.fireEventImmediately(EventDispatcher.java:619)
      at org.apache.felix.framework.util.EventDispatcher.run(EventDispatcher.java:816)
      at org.apache.felix.framework.util.EventDispatcher.access$000(EventDispatcher.java:42)
      at org.apache.felix.framework.util.EventDispatcher$1.run(EventDispatcher.java:94)
      at java.lang.Thread.run(Thread.java:613)

        Attachments

          Activity

            People

            • Assignee:
              logback-dev Logback dev list
              Reporter:
              olli Oliver Lietz
            • Votes:
              0 Vote for this issue
              Watchers:
              0 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: