dirstate: add doesn't need to call stat
authorMatt Mackall <mpm@selenic.com>
Sat, 21 Jul 2007 16:02:09 -0500
changeset 4911 8b6efc8fc23c
parent 4910 fd96bc61a18b
child 4912 312c845edef5
dirstate: add doesn't need to call stat
mercurial/dirstate.py
--- a/mercurial/dirstate.py	Sat Jul 21 16:02:09 2007 -0500
+++ b/mercurial/dirstate.py	Sat Jul 21 16:02:09 2007 -0500
@@ -217,8 +217,7 @@
         'mark a file added'
         self._dirty = True
         self._incpathcheck(f)
-        s = os.lstat(self._join(f))
-        self._map[f] = ('a', s.st_mode, s.st_size, s.st_mtime)
+        self._map[f] = ('a', 0, -1, -1)
         if f in self._copymap:
             del self._copymap[f]