Comment 6 for bug 1318657

Revision history for this message
David Mathog (mathog) wrote :

Much debugging later...

What is happening is apparently that change_def_references() in id-clash.cpp is setting the xlink:href value in the document's XML tree but for some reason or other the corresponding SPObject representation is not updated to match. The code in change_def_references() uses

                it->elem->getRepr()->setAttribute(it->attr, new_uri);

to set the value in the XML and that is working as it should. But coming out of importDefs() in document.cpp the corresponding SPObject still (and forever) has the old definition (like it was before the setAttribute) and that causes the rest of the problems. It may be that the XML is later written over by the SPObject form of the data - I have not debugged it that far.

Some flag needs to be set somewhere to force the SPObjects to be recreated from the XML??? Or is it necessary to set both the SPObject and its corresponding XML at the same time? Note that the code in question is pretty much identical to that in fix_up_refs() in id-clash.cpp, and that seems not to have the same problem.