# HG changeset patch # User Benoit Boissinot # Date 1130522260 25200 # Node ID 17e8c70fb670e9a2046dcb46a2d81875870becff # Parent d791c335fb7b8ea376d046721a064c95744f3819 fix dirstate.change: it should walk ignored files diff -r d791c335fb7b -r 17e8c70fb670 mercurial/dirstate.py --- a/mercurial/dirstate.py Thu Oct 27 13:49:15 2005 -0700 +++ b/mercurial/dirstate.py Fri Oct 28 10:57:40 2005 -0700 @@ -11,7 +11,7 @@ from node import * from i18n import gettext as _ from demandload import * -demandload(globals(), "time bisect stat util re") +demandload(globals(), "time bisect stat util re errno") class dirstate: def __init__(self, opener, ui, root): @@ -372,11 +372,16 @@ except KeyError: unknown.append(fn) continue - # XXX: what to do with file no longer present in the fs - # who are not removed in the dirstate ? - if src == 'm' and not type == 'r': - deleted.append(fn) - continue + if src == 'm': + try: + st = os.stat(fn) + except OSError, inst: + # XXX: what to do with file no longer present in the fs + # who are not removed in the dirstate ? + if inst.errno != errno.ENOENT: + raise + deleted.append(fn) + continue # check the common case first if type == 'n': if not st: