Commit 931b3549 931b354984a74776ad68145d03c4d3ca6e73fd82 by Sergey Poznyakoff

Do not count deleted messages into the total number of lines output.

1 parent 4757badf
Showing 1 changed file with 4 additions and 3 deletions
......@@ -179,12 +179,13 @@ mail_z (int argc, char **argv)
realcursor = cursor;
for (i = 0; i < nlines; i++)
for (i = 0; i < nlines && cursor <= total; )
{
mail_from(0, NULL);
if (mail_from(0, NULL) == 0)
i++;
cursor++;
}
cursor = realcursor;
return 1;
......