Uploaded image for project: 'Log4j 2'
  1. Log4j 2
  2. LOG4J2-517

Switch in log4j-1.2-api Category.getEffectiveLevel misses FATAL, OFF

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: 2.0-beta9
    • Fix Version/s: 2.0-rc1
    • Component/s: log4j 1.2 emulation
    • Labels:
      None

      Description

      Current:

          public final Level getEffectiveLevel() {
              switch (logger.getLevel().getStandardLevel()) {
                  case TRACE:
                      return Level.TRACE;
                  case DEBUG:
                      return Level.DEBUG;
                  case INFO:
                      return Level.INFO;
                  case WARN:
                      return Level.WARN;
                  default:
                      return Level.ERROR;
              }
          }
      

      Should be:

          public final Level getEffectiveLevel() {
              switch (logger.getLevel().getStandardLevel()) {
                  case TRACE:
                      return Level.TRACE;
                  case DEBUG:
                      return Level.DEBUG;
                  case INFO:
                      return Level.INFO;
                  case WARN:
                      return Level.WARN;
                  case ERROR:
                      return Level.ERROR;
                  case FATAL:
                      return Level.FATAL;
                  default:
                      return Level.OFF;
              }
          }
      

        Attachments

          Activity

            People

            • Assignee:
              remkop@yahoo.com Remko Popma
              Reporter:
              remkop@yahoo.com Remko Popma
            • Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: