store.py: accept empty repos
authorAdrian Buehlmann <adrian@cadifra.com>
Wed, 13 Aug 2008 20:18:41 -0500
changeset 6890 fddef0602859
parent 6889 c0bd7d8b69ef
child 6891 22cb82433842
store.py: accept empty repos Fixes a traceback on the server side when trying to streamclone an empty repo (this was *not* introduced by 80e51429cb9a).
mercurial/store.py
--- a/mercurial/store.py	Wed Aug 13 20:18:40 2008 -0500
+++ b/mercurial/store.py	Wed Aug 13 20:18:41 2008 -0500
@@ -69,6 +69,8 @@
             path = os.path.join(self.path, relpath)
         else:
             path = self.path
+        if not os.path.isdir(path):
+            return
         striplen = len(self.path) + len(os.sep)
         filetypes = ('.d', '.i')
         for f, size in _dirwalk(path, recurse):