aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAvatar Ciaran McCreesh <ciaran.mccreesh@googlemail.com> 2007-07-25 21:06:10 +0000
committerAvatar Ciaran McCreesh <ciaran.mccreesh@googlemail.com> 2007-07-25 21:06:10 +0000
commitc8a5b88a00dfc46fe54044bb9c5aa78f6e7caaf5 (patch)
treef6c9119a81edfa791fa8bb4af688f05a22a26f8f
parentadb49f92a08832d1b084f6767ad6637cfc44ee18 (diff)
downloadpaludis-c8a5b88a00dfc46fe54044bb9c5aa78f6e7caaf5.tar.gz
paludis-c8a5b88a00dfc46fe54044bb9c5aa78f6e7caaf5.tar.xz
Don't assume that a category dir exists
-rw-r--r--paludis/repositories/e/qa/stray_files.cc7
1 files changed, 4 insertions, 3 deletions
diff --git a/paludis/repositories/e/qa/stray_files.cc b/paludis/repositories/e/qa/stray_files.cc
index 1fe925b..81a5b67 100644
--- a/paludis/repositories/e/qa/stray_files.cc
+++ b/paludis/repositories/e/qa/stray_files.cc
@@ -36,9 +36,10 @@ paludis::erepository::stray_files_check(
const std::string & name
)
{
- for (DirIterator d(dir), d_end ; d != d_end ; ++d)
- if (stray(repo, *d))
- reporter.message(qaml_normal, name, "Stray file '" + stringify(*d) + "'");
+ if (dir.exists())
+ for (DirIterator d(dir), d_end ; d != d_end ; ++d)
+ if (stray(repo, *d))
+ reporter.message(qaml_normal, name, "Stray file '" + stringify(*d) + "'");
return true;
}