From: Sebastien GODARD Date: Sun, 24 Dec 2017 16:06:08 +0000 (+0100) Subject: Don't count CPU "all" twice when displaying a RESTART message X-Git-Tag: v11.7.1~27 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=3554642e9a6fb63413b21dada30eafcc90462155;p=sysstat Don't count CPU "all" twice when displaying a RESTART message file_hdr->sa_cpu_nr already includes CPU "all", so don't increment its number when setting nr_ini variable. Signed-off-by: Sebastien GODARD --- diff --git a/sa_common.c b/sa_common.c index 8bfbab2..8e83641 100644 --- a/sa_common.c +++ b/sa_common.c @@ -2510,7 +2510,7 @@ int print_special_record(struct record_header *record_hdr, unsigned int l_flags, * reallocate buffers if needed. */ p = get_activity_position(act, A_CPU, EXIT_IF_NOT_FOUND); - act[p]->nr_ini = file_hdr->sa_cpu_nr + 1; /* Dont't forget to count CPU "all" */ + act[p]->nr_ini = file_hdr->sa_cpu_nr; if (act[p]->nr_ini > act[p]->nr_allocated) { reallocate_all_buffers(act[p]); }