]> git.ipfire.org Git - pakfire.git/commitdiff
transactions: Fix showing freed space
authorMichael Tremer <michael.tremer@ipfire.org>
Mon, 12 Dec 2022 17:32:34 +0000 (17:32 +0000)
committerMichael Tremer <michael.tremer@ipfire.org>
Mon, 12 Dec 2022 17:32:34 +0000 (17:32 +0000)
Fixes: #13013
Signed-off-by: Michael Tremer <michael.tremer@ipfire.org>
src/libpakfire/transaction.c

index 8a8ca3af062407f653c4a3256d5ca76000711eb3..0812134906bbd9ee9dbe1374b0ad270bb47a4c68 100644 (file)
@@ -624,7 +624,7 @@ PAKFIRE_EXPORT char* pakfire_transaction_dump(struct pakfire_transaction* transa
        // How much more space do we need?
        ssize_t sizechange = pakfire_transaction_installsizechange(transaction);
        pakfire_transaction_add_usage_line(&lines, width,
-               (sizechange >= 0) ? _("Installed Size") : _("Freed Size"), sizechange);
+               (sizechange >= 0) ? _("Required Space") : _("Freed Space"), abs(sizechange));
 
        // Join all lines together
        char* string = pakfire_transaction_join_lines(lines);