pipe_progress: make it independent of printf machinery