Log4cxx
  1. Log4cxx
  2. LOGCXX-29

Appender attributes are not passed passed to setOption correctly.

    Details

    • Type: Bug Bug
    • Status: Resolved
    • Priority: Major Major
    • Resolution: Fixed
    • Affects Version/s: 0.9.7
    • Fix Version/s: 0.10.0
    • Component/s: Appender
    • Labels:
      None
    • Environment:
      Linux (but affects all platforms)

      Description

      Many appenders have a bug in their implementation of setOption.
      Instead of passing (option, value) to the superclasses' setOption
      method, they incorrectly pass the appender's name. For example:

      void FileAppender::setOption(const String& option,
      const String& value)
      {
      ...
      WriterAppender::setOption(name, value);
      ... ^^^^
      }

      This bug was probably not discovered before, because until now
      neither WriterAppender, nor AppenderSkeleton were handling
      attributes. But if such attributes are introduced (see LOGCXX-28)
      these typos break them for most handlers...

        Activity

        Martin Landers created issue -
        Martin Landers made changes -
        Field Original Value New Value
        Attachment log4cxx_optionpassing.patch [ 17984 ]
        Curt Arnold made changes -
        Assignee Michaël CATANZARITI [ mcatan ] Curt Arnold [ carnold@apache.org ]
        Status Open [ 1 ] Resolved [ 5 ]
        Fix Version/s 0.9.8 [ 10782 ]
        Resolution Fixed [ 1 ]

          People

          • Assignee:
            Curt Arnold
            Reporter:
            Martin Landers
          • Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved:

              Development