From: Mark Wooding Date: Sun, 6 Mar 2022 01:06:28 +0000 (+0000) Subject: multiprogress.c: Leave the cursor at the start of the last line. X-Git-Url: https://www.chiark.greenend.org.uk/ucgi/~mdw/git/dvdrip/commitdiff_plain/ce512975d256e096ea774610cf9ae6f1cc047984?ds=sidebyside multiprogress.c: Leave the cursor at the start of the last line. Things still go wrong when stray characters get echoed but it's less bad. I think. --- diff --git a/multiprogress.c b/multiprogress.c index 17ba4c0..0594f37 100644 --- a/multiprogress.c +++ b/multiprogress.c @@ -574,6 +574,7 @@ int progress_update(struct progress_state *progress) item->render(item, &render); progress->last_lines++; f |= f_any; if (progress->last_lines > render.height) break; } + if (f&f_any) put_sequence(tty, tty->cap.cr, 1); free_render_state(&render); return (0); }