From 71172ed97cd4cd45c6ae70e594ba351798d11909 Mon Sep 17 00:00:00 2001 From: Arnaldo Carvalho de Melo Date: Tue, 25 Oct 2011 13:45:16 -0200 Subject: perf ui: Improve handling sigwinch a bit No need to unblock it at each ui__getch() and also allow other users to check if a resize is needed, or force an refresh of terminal dimensions. The 'force' one shouldn't be needed, but its in a slow path, so leave it like that for now, I'll revisit this another day. Cc: David Ahern Cc: Frederic Weisbecker Cc: Mike Galbraith Cc: Paul Mackerras Cc: Peter Zijlstra Cc: Stephane Eranian Link: http://lkml.kernel.org/n/tip-aujchu6yx3bfy64non1rky0w@git.kernel.org Signed-off-by: Arnaldo Carvalho de Melo --- tools/perf/util/ui/progress.c | 1 + 1 file changed, 1 insertion(+) (limited to 'tools/perf/util/ui/progress.c') diff --git a/tools/perf/util/ui/progress.c b/tools/perf/util/ui/progress.c index 68d2c548abe3..295e366b6311 100644 --- a/tools/perf/util/ui/progress.c +++ b/tools/perf/util/ui/progress.c @@ -14,6 +14,7 @@ void ui_progress__update(u64 curr, u64 total, const char *title) if (use_browser <= 0) return; + ui__refresh_dimensions(true); pthread_mutex_lock(&ui__lock); y = SLtt_Screen_Rows / 2 - 2; SLsmg_set_color(0); -- cgit v1.2.3-59-g8ed1b