diff options
author | Eelco Dolstra <eelco.dolstra@logicblox.com> | 2013-04-26T10·07+0200 |
---|---|---|
committer | Eelco Dolstra <eelco.dolstra@logicblox.com> | 2013-04-26T10·07+0200 |
commit | 0374d9443732c184ab054a926058b9c5b973198f (patch) | |
tree | da0d372c90a7161daf02ceda895b511f914f800f /src | |
parent | 00f698eb8b93c9de50ebbadb946c5bf188e8fa98 (diff) |
addAdditionalRoots(): Check each path only once
Diffstat (limited to 'src')
-rw-r--r-- | src/libstore/gc.cc | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/libstore/gc.cc b/src/libstore/gc.cc index 113a7da15411..5c5c07e4c481 100644 --- a/src/libstore/gc.cc +++ b/src/libstore/gc.cc @@ -372,9 +372,9 @@ static void addAdditionalRoots(StoreAPI & store, PathSet & roots) string result = runProgram(rootFinder); - Strings paths = tokenizeString<Strings>(result, "\n"); + StringSet paths = tokenizeString<StringSet>(result, "\n"); - foreach (Strings::iterator, i, paths) { + foreach (StringSet::iterator, i, paths) { if (isInStore(*i)) { Path path = toStorePath(*i); if (roots.find(path) == roots.end() && store.isValidPath(path)) { |