dbertoni 01/12/14 09:45:41
Modified: c/src/XSLT ElemAttribute.cpp
Log:
Prefer the stylesheet author's prefix to the prefix that is already active.
(namespace134)
Revision Changes Path
1.34 +8 -1 xml-xalan/c/src/XSLT/ElemAttribute.cpp
Index: ElemAttribute.cpp
===================================================================
RCS file: /home/cvs/xml-xalan/c/src/XSLT/ElemAttribute.cpp,v
retrieving revision 1.33
retrieving revision 1.34
diff -u -r1.33 -r1.34
--- ElemAttribute.cpp 2001/12/14 16:52:25 1.33
+++ ElemAttribute.cpp 2001/12/14 17:45:41 1.34
@@ -217,7 +217,14 @@
const XalanDOMString* const prefix =
executionContext.getResultPrefixForNamespace(attrNameSpace);
- if(prefix != 0 && length(*prefix) != 0)
+ // If there is already a prefix for the
namespace, and it's length
+ // is not 0, and there is no prefix on the
attribute name, or
+ // it's equal to the prefix on the attribute,
then go ahead
+ // and use that prefix.
+ if(prefix != 0 &&
+ length(*prefix) != 0 &&
+ (indexOfNSSep == origAttrNameLength ||
+ equals(c_wstr(*prefix), c_wstr(attrName),
indexOfNSSep) == true))
{
if(indexOfNSSep < origAttrNameLength)
{
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]