Author: kkaempf
Date: Mon Jul 9 14:46:30 2007
New Revision: 39250
URL: http://svn.opensuse.org/viewcvs/yast?rev=39250&view=rev
Log:
clean up <locale> xml output
Modified:
trunk/core/libycp/src/Xmlcode.cc
trunk/core/libycp/src/YCode.cc
trunk/core/libycp/src/YExpression.cc
Modified: trunk/core/libycp/src/Xmlcode.cc
URL: http://svn.opensuse.org/viewcvs/yast/trunk/core/libycp/src/Xmlcode.cc?rev=39250&r1=39249&r2=39250&view=diff
==============================================================================
--- trunk/core/libycp/src/Xmlcode.cc (original)
+++ trunk/core/libycp/src/Xmlcode.cc Mon Jul 9 14:46:30 2007
@@ -877,12 +877,14 @@
const char *cptr = s.c_str();
const char *next;
- while( (next = strpbrk( cptr, "&<>" )) ) {
+ while( (next = strpbrk( cptr, "&<>'\"" )) ) {
result += string( cptr, next - cptr );
switch (*next) {
case '&': result += "&"; break;
case '<': result += "<"; break;
case '>': result += ">"; break;
+ case '"': result += """; break;
+ case '\'': result += "'"; break;
}
cptr = next + 1;
}
Modified: trunk/core/libycp/src/YCode.cc
URL: http://svn.opensuse.org/viewcvs/yast/trunk/core/libycp/src/YCode.cc?rev=39250&r1=39249&r2=39250&view=diff
==============================================================================
--- trunk/core/libycp/src/YCode.cc (original)
+++ trunk/core/libycp/src/YCode.cc Mon Jul 9 14:46:30 2007
@@ -410,8 +410,8 @@
}
if (m_value.isNull())
return str << "<null/>";
-
- return m_value->toXml (str, 0 );
+ m_value->toXml (str, 0 );
+ return str;
}
@@ -507,12 +507,12 @@
return Bytecode::writeCharp (str, m_domain->first);
}
+// see also YELocale::toXml
std::ostream &
YLocale::toXml (std::ostream & str, int indent ) const
{
- str << "