Imported Upstream version 0.6.29
[platform/upstream/libsolv.git] / src / solver_private.h
index f8df8c7..a234223 100644 (file)
@@ -17,6 +17,7 @@ extern void solver_run_sat(Solver *solv, int disablerules, int doweak);
 extern void solver_reset(Solver *solv);
 
 extern int solver_splitprovides(Solver *solv, Id dep, Map *m);
+extern int solver_dep_fulfilled_cplx(Solver *solv, Reldep *rd);
 
 static inline int
 solver_dep_fulfilled(Solver *solv, Id dep)
@@ -27,18 +28,8 @@ solver_dep_fulfilled(Solver *solv, Id dep)
   if (ISRELDEP(dep))
     {
       Reldep *rd = GETRELDEP(pool, dep);
-      if (rd->flags == REL_AND || rd->flags == REL_COND)
-        {
-          if (!solver_dep_fulfilled(solv, rd->name))
-            return 0;
-          return solver_dep_fulfilled(solv, rd->evr);
-        }
-      if (rd->flags == REL_OR)
-       {
-          if (solver_dep_fulfilled(solv, rd->name))
-           return 1;
-          return solver_dep_fulfilled(solv, rd->evr);
-       }
+      if (rd->flags == REL_COND || rd->flags == REL_UNLESS || rd->flags == REL_AND || rd->flags == REL_OR)
+       return solver_dep_fulfilled_cplx(solv, rd);
       if (rd->flags == REL_NAMESPACE && rd->name == NAMESPACE_SPLITPROVIDES)
         return solver_splitprovides(solv, rd->evr, 0);
     }