Uploaded image for project: 'Log4net'
  1. Log4net
  2. LOG4NET-209

XmlLayout.FormatXml calls wrong overload of XmlWriter.WriteStartElement

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Reopened
    • Major
    • Resolution: Unresolved
    • 1.2.10
    • None
    • Other
    • None
    • .NET 3.5 SP1

    Description

      FormatXml calls WriteStartElement using prefixed element names (e.g. "log4net:event"), but it calls the overload of WriteStartElement that expects a local name. Thus, if it writes to an xml writer that actually checks such things, it crashes. Instead, it should call the overload that separates the prefix from the local name. E.g.: writer.WriteStartElement(this.m_prefix, this.m_elmEvent, null).

      Attachments

        Activity

          People

            Unassigned Unassigned
            cheetah Matthew Gabeler-Lee
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

              Created:
              Updated: