[slf4j-dev] [GIT] SLF4J: Simple Logging Facade for Java branch, master, updated. 81accae38e8ddb09b72cf41be557f3c3cacc48bd

added by portage for gitosis-gentoo git-noreply at pixie.qos.ch
Tue Sep 1 18:33:48 CEST 2009


This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "SLF4J: Simple Logging Facade for Java".

The branch, master has been updated
       via  81accae38e8ddb09b72cf41be557f3c3cacc48bd (commit)
      from  edf889671c1a126ac8722925d731375f75d3f200 (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.

- Log -----------------------------------------------------------------
http://git.qos.ch/gitweb/?p=slf4j.git;a=commit;h=81accae38e8ddb09b72cf41be557f3c3cacc48bd
http://github.com/ceki/slf4j/commit/81accae38e8ddb09b72cf41be557f3c3cacc48bd

commit 81accae38e8ddb09b72cf41be557f3c3cacc48bd
Author: Ceki Gulcu <ceki at qos.ch>
Date:   Tue Sep 1 18:31:35 2009 +0200

    Fixed bug 146
    
    http://bugzilla.slf4j.org/show_bug.cgi?id=146

diff --git a/slf4j-api/src/main/java/org/slf4j/LoggerFactory.java b/slf4j-api/src/main/java/org/slf4j/LoggerFactory.java
index 4d6b3d1..646b1ea 100644
--- a/slf4j-api/src/main/java/org/slf4j/LoggerFactory.java
+++ b/slf4j-api/src/main/java/org/slf4j/LoggerFactory.java
@@ -188,7 +188,12 @@ public final class LoggerFactory {
 
   private static void singleImplementationSanityCheck() {
     try {
-      Enumeration paths = LoggerFactory.class.getClassLoader().getResources(
+      ClassLoader loggerFactoryClassLoader = LoggerFactory.class.getClassLoader();
+      if(loggerFactoryClassLoader == null) {
+        // see http://bugzilla.slf4j.org/show_bug.cgi?id=146
+        return; // better than a null pointer exception
+      }
+      Enumeration paths = loggerFactoryClassLoader.getResources(
           STATIC_LOGGER_BINDER_PATH);
       List implementationList = new ArrayList();
       while (paths.hasMoreElements()) {

-----------------------------------------------------------------------

Summary of changes:
 .../src/main/java/org/slf4j/LoggerFactory.java     |    7 ++++++-
 1 files changed, 6 insertions(+), 1 deletions(-)


hooks/post-receive
-- 
SLF4J: Simple Logging Facade for Java



More information about the slf4j-dev mailing list