浏览代码

remove unneeded sort from scandir_generic()

Alexander 'Leo' Bergolth 7 年之前
父节点
当前提交
b5fbeed6ed
共有 1 个文件被更改,包括 1 次插入1 次删除
  1. 1 1
      src/borg/helpers.py

+ 1 - 1
src/borg/helpers.py

@@ -2086,7 +2086,7 @@ class GenericDirEntry:
 
 
 def scandir_generic(path='.'):
 def scandir_generic(path='.'):
     """Like os.listdir(), but yield DirEntry objects instead of returning a list of names."""
     """Like os.listdir(), but yield DirEntry objects instead of returning a list of names."""
-    for name in sorted(os.listdir(path)):
+    for name in os.listdir(path):
         yield GenericDirEntry(path, name)
         yield GenericDirEntry(path, name)