diff --git a/src/p7/main.c b/src/p7/main.c index 1269c80..16d1e39 100644 --- a/src/p7/main.c +++ b/src/p7/main.c @@ -126,15 +126,10 @@ static void sendfile_display(p7ushort_t id, p7ushort_t total) sendfile_display_initialized = 1; /* put initial buffer */ fputs(buf, stdout); - /* save cursor position */ - fputs("\x1B[s", stdout); /* we're done */ return ; } - /* id and total start from 1, let them start from zero */ - id--; total--; - /* modify buffer */ /* - # - */ int current = 38 * id / total; @@ -145,8 +140,7 @@ static void sendfile_display(p7ushort_t id, p7ushort_t total) /* put it */ fputs(buf, stdout); - /* force cursor position */ - fputs("\x1B""8", stdout); + fflush(stdout); } /**