Details

    • Type: Question
    • Status: Resolved
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: 2.0-beta5
    • Fix Version/s: 2.0-beta6
    • Component/s: Core, log4j 1.2 emulation
    • Labels:
      None

      Description

      Not 100% sure, but this code looked a bit strange:
      (o.a.l.l.core.Logger line 65)
      public Logger getParent() {
      final LoggerConfig lc = config.loggerConfig.getParent();
      if (lc == null)

      { return null; }

      if (context.hasLogger(lc.getName()))

      { return context.getLogger(getName(), getMessageFactory()); // <------- }

      return new Logger(context, getName(), this.getMessageFactory()); // <-------
      }

      the last two return statements use the name of this logger instead of the parent name lc.getName().
      Is that correct?

      (this method is not used in core internally but is used in the logtj12-api module, by Category#getParent)
      I'll try to write a JUnit test for this later, still need to figure out how.

        Attachments

          Activity

            People

            • Assignee:
              ralph.goers@dslextreme.com Ralph Goers
              Reporter:
              remkop@yahoo.com Remko Popma
            • Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: