##// END OF EJS Templates
dirstate: ignore symlinks when fs cannot handle them (issue1888)...
Martin Geisler -
r11769:ca6cebd8 stable
parent child Browse files
Show More
@@ -625,6 +625,8 b' class dirstate(object):'
625 dadd = deleted.append
625 dadd = deleted.append
626 cadd = clean.append
626 cadd = clean.append
627
627
628 lnkkind = stat.S_IFLNK
629
628 for fn, st in self.walk(match, subrepos, listunknown,
630 for fn, st in self.walk(match, subrepos, listunknown,
629 listignored).iteritems():
631 listignored).iteritems():
630 if fn not in dmap:
632 if fn not in dmap:
@@ -640,13 +642,19 b' class dirstate(object):'
640 if not st and state in "nma":
642 if not st and state in "nma":
641 dadd(fn)
643 dadd(fn)
642 elif state == 'n':
644 elif state == 'n':
645 # The "mode & lnkkind != lnkkind or self._checklink"
646 # lines are an expansion of "islink => checklink"
647 # where islink means "is this a link?" and checklink
648 # means "can we check links?".
643 if (size >= 0 and
649 if (size >= 0 and
644 (size != st.st_size
650 (size != st.st_size
645 or ((mode ^ st.st_mode) & 0100 and self._checkexec))
651 or ((mode ^ st.st_mode) & 0100 and self._checkexec))
652 and (mode & lnkkind != lnkkind or self._checklink)
646 or size == -2 # other parent
653 or size == -2 # other parent
647 or fn in self._copymap):
654 or fn in self._copymap):
648 madd(fn)
655 madd(fn)
649 elif time != int(st.st_mtime):
656 elif (time != int(st.st_mtime)
657 and (mode & lnkkind != lnkkind or self._checklink)):
650 ladd(fn)
658 ladd(fn)
651 elif listclean:
659 elif listclean:
652 cadd(fn)
660 cadd(fn)
General Comments 0
You need to be logged in to leave comments. Login now