]> git.ipfire.org Git - thirdparty/libsolv.git/commitdiff
Fix repo_unset clearing wrong field for SOLVABLE_SUPPLEMENTS 621/head
authorIgor Raits <igor.raits@gmail.com>
Wed, 6 May 2026 06:48:24 +0000 (08:48 +0200)
committerIgor Raits <igor.raits@gmail.com>
Wed, 6 May 2026 06:48:24 +0000 (08:48 +0200)
The case for SOLVABLE_SUPPLEMENTS was missing a return statement
and fell through to SOLVABLE_ENHANCES, so calling repo_unset() with
SOLVABLE_SUPPLEMENTS cleared both s->supplements and s->enhances.
Bug has been present since the function (originally repo_set_deleted)
was added in 5f153e32 (2012).

src/repo.c

index 1aee4a83bb8490b7644a6d45e2d2a45d3b152191..6f6b85bfea3ddf8434a9b3523ed1b45cf2a47e80 100644 (file)
@@ -1621,6 +1621,7 @@ repo_unset(Repo *repo, Id p, Id keyname)
          return;
        case SOLVABLE_SUPPLEMENTS:
          s->supplements = 0;
+         return;
        case SOLVABLE_ENHANCES:
          s->enhances = 0;
          return;