[CalendarServer-changes] [284] CalendarServer/trunk/lib-patches/Twisted/twisted.web2.dav.static. patch

source_changes at macosforge.org source_changes at macosforge.org
Fri Oct 20 16:55:22 PDT 2006


Revision: 284
          http://trac.macosforge.org/projects/calendarserver/changeset/284
Author:   cdaboo at apple.com
Date:     2006-10-20 16:55:21 -0700 (Fri, 20 Oct 2006)

Log Message:
-----------
Don't use listChildren to determine if a resource is a collection - that's expensive. A stat will do nicely.

Modified Paths:
--------------
    CalendarServer/trunk/lib-patches/Twisted/twisted.web2.dav.static.patch

Modified: CalendarServer/trunk/lib-patches/Twisted/twisted.web2.dav.static.patch
===================================================================
--- CalendarServer/trunk/lib-patches/Twisted/twisted.web2.dav.static.patch	2006-10-20 15:18:50 UTC (rev 283)
+++ CalendarServer/trunk/lib-patches/Twisted/twisted.web2.dav.static.patch	2006-10-20 23:55:21 UTC (rev 284)
@@ -37,7 +37,15 @@
      def davComplianceClasses(self):
          return ("1", "access-control") # Add "2" when we have locking
  
-@@ -98,6 +104,50 @@
+@@ -87,7 +93,6 @@
+         """
+         See L{IDAVResource.isCollection}.
+         """
+-        for child in self.listChildren(): return True
+         return self.fp.isdir()
+ 
+     ##
+@@ -98,6 +103,50 @@
          return succeed(davPrivilegeSet)
  
      ##
@@ -88,7 +96,7 @@
      # Workarounds for issues with File
      ##
  
-@@ -133,11 +183,22 @@
+@@ -133,11 +182,22 @@
                      # Render from the index file
                      standin = self.createSimilarFile(ifp.path)
                  else:

-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.macosforge.org/pipermail/calendarserver-changes/attachments/20061020/6816fc18/attachment.html


More information about the calendarserver-changes mailing list