From: Mark Wooding Date: Fri, 25 Mar 2022 01:31:51 +0000 (+0000) Subject: multiprogress.c (clear_progress): Don't check for output errors. X-Git-Url: https://git.distorted.org.uk/~mdw/dvdrip/commitdiff_plain/0d5797b0ecee10bb6a03937b60766cdea96105b3?hp=5b3da03ff5d1b1694dfb2e319ad855ad6e30a4f7 multiprogress.c (clear_progress): Don't check for output errors. Nobody's watching to see if we found any. Indeed, we might as well not return anything at all. So, err, don't. --- diff --git a/multiprogress.c b/multiprogress.c index 3318415..450f7f1 100644 --- a/multiprogress.c +++ b/multiprogress.c @@ -408,8 +408,8 @@ void progress_set_bgcolour(const struct progress_ttyinfo *tty, int colour) #endif #define CLRF_ALL 1u -static int clear_progress(struct progress_state *progress, - struct progress_render_state *render, unsigned f) +static void clear_progress(struct progress_state *progress, + struct progress_render_state *render, unsigned f) { const struct progress_ttyinfo *tty = &progress->tty; unsigned ndel, nleave; @@ -436,8 +436,6 @@ static int clear_progress(struct progress_state *progress, } } progress->last_lines = 0; - if (ferror(tty->fp)) return (-1); - return (0); } int progress_clear(struct progress_state *progress)