From 2fe85f5a7e382b920a7cd92683fb1b4e7c121937 Mon Sep 17 00:00:00 2001 From: Sebastien GODARD Date: Fri, 10 May 2019 18:23:00 +0200 Subject: [PATCH] sadf: Fix PCP and SVG output for filesystem statistics When the mount point had to be displayed instead of the filesystem name with sar's option -F (i.e. the user entered "-F MOUNT" instead of just "-F"), no data were found by sadf -g (SVG output) and sadf -l (PCP output). This patch fixes the problem. Signed-off-by: Sebastien GODARD --- sadf_misc.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/sadf_misc.c b/sadf_misc.c index 6a6ecd1..452839e 100644 --- a/sadf_misc.c +++ b/sadf_misc.c @@ -1505,7 +1505,9 @@ __nr_t count_new_filesystem(struct activity *a, int curr) for (i = 0; i < a->nr[curr]; i++) { sfc = (struct stats_filesystem *) ((char *) a->buf[curr] + i * a->msize); - nr += add_list_item(&(a->item_list), sfc->fs_name, MAX_FS_LEN); + nr += add_list_item(&(a->item_list), + DISPLAY_MOUNT(a->opt_flags) ? sfc->mountp : sfc->fs_name, + MAX_FS_LEN); } return nr; -- 2.40.0