aboutsummaryrefslogtreecommitdiff
path: root/src/nvim/hardcopy.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/nvim/hardcopy.c')
-rw-r--r--src/nvim/hardcopy.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/nvim/hardcopy.c b/src/nvim/hardcopy.c
index d072277d38..3898a29bca 100644
--- a/src/nvim/hardcopy.c
+++ b/src/nvim/hardcopy.c
@@ -731,7 +731,8 @@ void ex_hardcopy(exarg_T *eap)
if (got_int || settings.user_abort)
goto print_fail;
- assert(prtpos.bytes_printed * 100 > prtpos.bytes_printed);
+ assert(prtpos.bytes_printed == 0
+ || prtpos.bytes_printed * 100 > prtpos.bytes_printed);
sprintf((char *)IObuff, _("Printing page %d (%zu%%)"),
page_count + 1 + side,
prtpos.bytes_printed * 100 / bytes_to_print);