vserver plugin: constify
authorRuben Kerkhof <ruben@rubenkerkhof.com>
Sat, 5 Mar 2016 15:42:24 +0000 (16:42 +0100)
committerRuben Kerkhof <ruben@rubenkerkhof.com>
Sat, 5 Mar 2016 15:42:24 +0000 (16:42 +0100)
src/vserver.c

index bd2e867..6c09f43 100644 (file)
@@ -215,7 +215,7 @@ static int vserver_read (void)
                {
                        derive_t rx;
                        derive_t tx;
-                       char *type_instance;
+                       const char *type_instance;
 
                        if (strsplit (buffer, cols, 4) < 4)
                                continue;
@@ -265,7 +265,7 @@ static int vserver_read (void)
 
                        if (2 == n)
                        {
-                               char   *type_instance;
+                               const char *type_instance;
                                gauge_t value;
 
                                if (0 == strcmp (cols[0], "nr_threads:"))
@@ -314,8 +314,8 @@ static int vserver_read (void)
 
                while ((fh != NULL) && (NULL != fgets (buffer, BUFSIZE, fh)))
                {
-                       char *type = "vs_memory";
-                       char *type_instance;
+                       const char *type = "vs_memory";
+                       const char *type_instance;
                        gauge_t value;
 
                        if (strsplit (buffer, cols, 2) < 2)