提交 2310e631 编写于 作者: B Bing Bu Cao 提交者: Ján Tomko

Fix buffer size in linuxNodeGetCPUstats

94f82053 added a space to the string but didn't change the buffer size.
Signed-off-by: NBing Bu Cao <mars@linux.vnet.ibm.com>
Signed-off-by: NJán Tomko <jtomko@redhat.com>
上级 6b29eb84
......@@ -691,7 +691,7 @@ linuxNodeGetCPUStats(FILE *procstat,
char line[1024];
unsigned long long usr, ni, sys, idle, iowait;
unsigned long long irq, softirq, steal, guest, guest_nice;
char cpu_header[3 + INT_BUFSIZE_BOUND(cpuNum)];
char cpu_header[4 + INT_BUFSIZE_BOUND(cpuNum)];
if ((*nparams) == 0) {
/* Current number of cpu stats supported by linux */
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册