[GME-commit] GMESRC/GME/XmlBackEnd CoreXmlFile.cpp,1.11,1.12
gme-commit at list.isis.vanderbilt.edu
gme-commit at list.isis.vanderbilt.edu
Tue Jun 5 16:43:13 CDT 2007
Update of /project/gme-repository/GMESRC/GME/XmlBackEnd
In directory escher:/tmp/cvs-serv20241
Modified Files:
CoreXmlFile.cpp
Log Message:
Overwrite attrVal only if special_value (CDATA section) really! found.
This will allow for smooth upgrades.
CVS User: Zoltan Molnar, ISIS (zolmol)
Index: CoreXmlFile.cpp
===================================================================
RCS file: /project/gme-repository/GMESRC/GME/XmlBackEnd/CoreXmlFile.cpp,v
retrieving revision 1.11
retrieving revision 1.12
diff -C2 -d -r1.11 -r1.12
*** CoreXmlFile.cpp 5 Jun 2007 20:26:42 -0000 1.11
--- CoreXmlFile.cpp 5 Jun 2007 21:43:11 -0000 1.12
***************
*** 2336,2339 ****
--- 2336,2340 ----
// multiline case?
+ bool spec_value_found = false; // will ensure smooth upgrade from old style xmlbackend
bool spec_attr = spec_care && ( attribToken == "StrValue" || attribToken == "RegNodeValue");
if( spec_attr)
***************
*** 2349,2352 ****
--- 2350,2354 ----
{
spec_value = XMLString::transcode( ((DOMCDATASection*)node)->getTextContent());
+ spec_value_found = true;
break;
}
***************
*** 2372,2376 ****
it2->second->fromString(attrVal);
! if( spec_attr) // spec_care is also true
it2->second->fromString( spec_value.c_str());
}
--- 2374,2379 ----
it2->second->fromString(attrVal);
! // use the spec_value only if really found the CDATA node
! if( spec_attr && spec_value_found) // spec_care is also true
it2->second->fromString( spec_value.c_str());
}
More information about the GME-commit
mailing list