Uploaded image for project: 'Axis2-C'
  1. Axis2-C
  2. AXIS2C-1591

axiom_element_add_attribute and duplicate names

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Open
    • Minor
    • Resolution: Unresolved
    • 1.7.0
    • 1.7.0
    • xml/om

    Description

      in axiom_element_add_attribute, the attribute is added to the hash of attributes in om_element->attributes
      based on the name (axutil_qname_to_string).
      If an attribute with the same name is already in the hash, that entry is overwritten and thus, will never be freed.
      This seems to be the case always if several xml nodes have the same namespace - the attribute value itself is not used there, or are
      we just talking namespace attributes here?

      I don't even begin to understand what the role of the attributes is, and what happes, if the attributes are stored with different names or such.
      For the moment, I will try to create two hashes, one for the attributes that are used, and one for the attributes that just have to be freed. Of course, a list would be enough for the latter.

      Attachments

        1. om_element.c.patch
          2 kB
          Sebastian Brandt

        Issue Links

          Activity

            People

              Unassigned Unassigned
              csb-ac Sebastian Brandt
              Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

                Created:
                Updated: