summaryrefslogtreecommitdiff
path: root/apt-pkg/algorithms.cc
diff options
context:
space:
mode:
authorArch Librarian <arch@canonical.com>2004-09-20 16:51:30 +0000
committerArch Librarian <arch@canonical.com>2004-09-20 16:51:30 +0000
commit43d017d69796a5093cb12506ec59285a34915b7f (patch)
tree1591e63d3dc4d89e02b00f4e5f103944e7a6c0bc /apt-pkg/algorithms.cc
parentfcf85120ef8c7e953a23a49768c0d5b84385efcd (diff)
New OR globbing mechanism
Author: jgg Date: 1998-11-14 07:20:06 GMT New OR globbing mechanism
Diffstat (limited to 'apt-pkg/algorithms.cc')
-rw-r--r--apt-pkg/algorithms.cc15
1 files changed, 4 insertions, 11 deletions
diff --git a/apt-pkg/algorithms.cc b/apt-pkg/algorithms.cc
index c419022ff..210095810 100644
--- a/apt-pkg/algorithms.cc
+++ b/apt-pkg/algorithms.cc
@@ -1,6 +1,6 @@
// -*- mode: cpp; mode: fold -*-
// Description /*{{{*/
-// $Id: algorithms.cc,v 1.10 1998/11/14 03:32:36 jgg Exp $
+// $Id: algorithms.cc,v 1.11 1998/11/14 07:20:06 jgg Exp $
/* ######################################################################
Algorithms - A set of misc algorithms
@@ -671,16 +671,9 @@ bool pkgProblemResolver::Resolve(bool BrokenFix)
for (pkgCache::DepIterator D = Cache[I].InstVerIter(Cache).DependsList(); D.end() == false;)
{
// Compute a single dependency element (glob or)
- pkgCache::DepIterator Start = D;
- pkgCache::DepIterator End = D;
- unsigned char State = 0;
- for (bool LastOR = true; D.end() == false && LastOR == true; D++)
- {
- State |= Cache[D];
- LastOR = (D->CompareOp & pkgCache::Dep::Or) == pkgCache::Dep::Or;
- if (LastOR == true)
- End = D;
- }
+ pkgCache::DepIterator Start;
+ pkgCache::DepIterator End;
+ D.GlobOr(Start,End);
// We only worry about critical deps.
if (End.IsCritical() != true)