# HG changeset patch
# User Mads Kiilerich <madski@unity3d.com>
# Date 2012-12-13 18:19:06
# Node ID a907826c158cf53b8c3d5381323c039a10409c63
# Parent  e388273f3ad175904e06cbe7edb0bd250c95b9ab

largefiles: don't walk through all ignored files

Problem: 'hg status' with largefiles enabled would walk through all the files
that .hgignore said should be ignored. That made it slow if a lot of files were
.hgignored or the cache was cold.

It seems like there was a reason to this, but other improvements has rendered
this unnecessary.

Solution: .hgignore is now only ignored when that is requested (--ignore).

This is a minimal 'stable' change. There is room for other improvement.

diff --git a/hgext/largefiles/reposetup.py b/hgext/largefiles/reposetup.py
--- a/hgext/largefiles/reposetup.py
+++ b/hgext/largefiles/reposetup.py
@@ -164,10 +164,8 @@ def reposetup(ui, repo):
                 m = copy.copy(match)
                 m._files = tostandins(m._files)
 
-                # Get ignored files here even if we weren't asked for them; we
-                # must use the result here for filtering later
                 result = super(lfilesrepo, self).status(node1, node2, m,
-                    True, clean, unknown, listsubrepos)
+                    ignored, clean, unknown, listsubrepos)
                 if working:
                     try:
                         # Any non-largefiles that were explicitly listed must be