Imported Upstream version 0.6.29
[platform/upstream/libsolv.git] / tools / cudftest.c
index 01ce117..75aeef5 100644 (file)
@@ -68,7 +68,7 @@ main(int argc, char **argv)
     }
   if (argc < 2)
     {
-      fprintf(stderr, "Usage: cudftest <cudfin> [cudfout]");
+      fprintf(stderr, "Usage: cudftest <cudfin> [cudfout]\n");
       exit(1);
     }
   cudfin = argv[1];
@@ -87,6 +87,8 @@ main(int argc, char **argv)
   repo = repo_create(pool, "repo");
   queue_init(&job);
   repo_add_cudf(repo, installed, fp, &job, 0);
+  fclose(fp);
+
   pool_createwhatprovides(pool);
 
   /* debug */
@@ -100,7 +102,7 @@ main(int argc, char **argv)
   solver_set_flag(solv, SOLVER_FLAG_ALLOW_UNINSTALL, 1);
   /* solver_set_flag(solv, SOLVER_FLAG_IGNORE_RECOMMENDED, 1); */
 
-  queue_push2(&job, SOLVER_VERIFY, SOLVER_SOLVABLE_ALL);
+  queue_push2(&job, SOLVER_VERIFY | SOLVER_SOLVABLE_ALL, 0);
   if (solver_solve(solv, &job) != 0)
     {
       int problem;