[Zope-Checkins] CVS: Zope/lib/python/OFS - PropertySheets.py:1.79

Andreas Jung andreas@zope.com
Fri, 26 Oct 2001 10:17:02 -0400


Update of /cvs-repository/Zope/lib/python/OFS
In directory cvs.zope.org:/tmp/cvs-serv10900/lib/python/OFS

Modified Files:
	PropertySheets.py 
Log Message:
WebDAV: Zope escaped nested object properties derived from
internal dav__* functions in PropertySheets.py although they
are considered to be safe and do not need any escaping. This 
caused Zope to be completely incomplete with Windows XP. Fixed !



=== Zope/lib/python/OFS/PropertySheets.py 1.78 => 1.79 ===
             name, type=item['id'], item.get('type','string')
             value=self.getProperty(name)
+
             if type=='tokens':
                 value=join(str(value), ' ')
             elif type=='lines':
@@ -376,7 +377,10 @@
                 # Quote non-xml items here?
                 attrs='' 
 
-            prop='  <n:%s%s>%s</n:%s>' % (name, attrs, xml_escape(value), name)
+            if hasattr(self,"dav__"+name):
+                prop='  <n:%s%s>%s</n:%s>' % (name, attrs, value, name)
+            else:
+                prop='  <n:%s%s>%s</n:%s>' % (name, attrs, xml_escape(value), name)
 
             result.append(prop)
         if not result: return ''