Skip to content

Commit

Permalink
repair: Fix incorrect progress when refs are skipped
Browse files Browse the repository at this point in the history
Issue was shown in this comment:

#3542 (comment)
  • Loading branch information
refi64 authored and alexlarsson committed Sep 17, 2021
1 parent f15f926 commit 86659a2
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion app/flatpak-builtins-repair.c
Original file line number Diff line number Diff line change
Expand Up @@ -355,6 +355,8 @@ flatpak_builtin_repair (int argc, char **argv, GCancellable *cancellable, GError
g_autoptr(FlatpakDecomposed) ref = NULL;
g_autofree char *origin = NULL;

i++;

if (!ostree_parse_refspec (refspec, &remote, &ref_name, error))
return FALSE;

Expand Down Expand Up @@ -388,7 +390,7 @@ flatpak_builtin_repair (int argc, char **argv, GCancellable *cancellable, GError
if (flatpak_fancy_output ())
g_print ("\033[A\r\033[K");

g_print (_("[%d/%d] Verifying %s…\n"), ++i, g_hash_table_size (all_refs), refspec);
g_print (_("[%d/%d] Verifying %s…\n"), i, g_hash_table_size (all_refs), refspec);

status = fsck_commit (repo, checksum, object_status_cache);
if (status != FSCK_STATUS_OK)
Expand Down

0 comments on commit 86659a2

Please sign in to comment.