aboutsummaryrefslogtreecommitdiffstats
path: root/plugin_proc_stat.c
diff options
context:
space:
mode:
authorreinelt <reinelt@3ae390bd-cb1e-0410-b409-cd5a39f66f1f>2004-03-03 04:44:16 +0000
committerreinelt <reinelt@3ae390bd-cb1e-0410-b409-cd5a39f66f1f>2004-03-03 04:44:16 +0000
commitb9a217e0dc5906e07b9f1e4674e9b797b6dd9b46 (patch)
treebf6491cefb0134736fc5f971226f54074be7324f /plugin_proc_stat.c
parent9ef4282e9e32e857f4d0cac9df6d58f2cba159f4 (diff)
downloadlcd4linux-b9a217e0dc5906e07b9f1e4674e9b797b6dd9b46.tar.gz
[lcd4linux @ 2004-03-03 04:44:16 by reinelt]
changes (cosmetics?) to the big patch from Martin hash patch un-applied git-svn-id: https://ssl.bulix.org/svn/lcd4linux/trunk@385 3ae390bd-cb1e-0410-b409-cd5a39f66f1f
Diffstat (limited to 'plugin_proc_stat.c')
-rw-r--r--plugin_proc_stat.c12
1 files changed, 8 insertions, 4 deletions
diff --git a/plugin_proc_stat.c b/plugin_proc_stat.c
index d3b4815..72de48e 100644
--- a/plugin_proc_stat.c
+++ b/plugin_proc_stat.c
@@ -1,4 +1,4 @@
-/* $Id: plugin_proc_stat.c,v 1.16 2004/03/03 03:47:04 reinelt Exp $
+/* $Id: plugin_proc_stat.c,v 1.17 2004/03/03 04:44:16 reinelt Exp $
*
* plugin for /proc/stat parsing
*
@@ -23,6 +23,10 @@
*
*
* $Log: plugin_proc_stat.c,v $
+ * Revision 1.17 2004/03/03 04:44:16 reinelt
+ * changes (cosmetics?) to the big patch from Martin
+ * hash patch un-applied
+ *
* Revision 1.16 2004/03/03 03:47:04 reinelt
* big patch from Martin Hejl:
* - use qprintf() where appropriate
@@ -103,8 +107,8 @@
#include "debug.h"
#include "plugin.h"
-#include "hash.h"
#include "qprintf.h"
+#include "hash.h"
static HASH Stat = { 0, };
@@ -209,7 +213,7 @@ static int parse_proc_stat (void)
while (strchr(delim, *beg)) beg++;
if ((end=strpbrk(beg, delim))) *end='\0';
if (i==0)
- strncpy(num,"sum",sizeof(num));
+ strcpy(num, "sum");
else
qprintf(num, sizeof(num), "%d", i-1);
hash_set2 ("intr", num, beg);
@@ -353,5 +357,5 @@ int plugin_init_proc_stat (void)
void plugin_exit_proc_stat(void)
{
- hash_destroy(&Stat);
+ hash_destroy(&Stat);
}