--- polipo_trimcache.old +++ polipo_trimcache @@ -261,6 +261,7 @@ """Recursively transverses a given directory. Returns a tuple of 0) a list of all found files as CacheObject instances, and 1) a list of all found directories as CacheDir instances (except for the given root directory). Note that the return values are flat lists and not some sort of tree structure. If parent is given, each file in the given directory will be assigned its value as the parent directory, and the children attribute of the parent will be assigned the number of children found in the given directory.""" debug_msg ("Entering directory: %s" % dir) + time.sleep(0.1) cobjs = [] cdirs = [] @@ -272,6 +273,8 @@ continue file_stat = os.lstat (file_full) + time.sleep(0.06) + if stat.S_ISDIR (file_stat.st_mode): cfile = CacheDir (parent) cdirs.append (cfile)