[Zope3-checkins] CVS: Zope3/src/zope/app/fssync - committer.py:1.6

Guido van Rossum guido@python.org
Thu, 29 May 2003 15:51:35 -0400


Update of /cvs-repository/Zope3/src/zope/app/fssync
In directory cvs.zope.org:/tmp/cvs-serv11649

Modified Files:
	committer.py 
Log Message:
Add ".", ".." and anything containing "/" to the names explicitly
refused; these are special to traverseName() even if the filesystem
syntax is different.


=== Zope3/src/zope/app/fssync/committer.py 1.5 => 1.6 ===
--- Zope3/src/zope/app/fssync/committer.py:1.5	Thu May 29 14:04:26 2003
+++ Zope3/src/zope/app/fssync/committer.py	Thu May 29 15:51:34 2003
@@ -88,8 +88,12 @@
         if (os.sep in name or
             (os.altsep and os.altsep in name) or
             name == os.curdir or
-            name == os.pardir):
-            # This name can't be mapped safely to the filesystem :-(
+            name == os.pardir or
+            name == "." or
+            name == ".." or
+            "/" in name):
+            # This name can't be mapped safely to the filesystem
+            # or it is a magic value for traverseName (".", "..", "/")
             raise SynchronizationError("invalid separator in name %r" % name)
 
         if not name: