summaryrefslogtreecommitdiff
path: root/multiload/linux-proc.c
diff options
context:
space:
mode:
Diffstat (limited to 'multiload/linux-proc.c')
-rw-r--r--multiload/linux-proc.c5
1 files changed, 2 insertions, 3 deletions
diff --git a/multiload/linux-proc.c b/multiload/linux-proc.c
index 0a011971..8923c9ac 100644
--- a/multiload/linux-proc.c
+++ b/multiload/linux-proc.c
@@ -103,7 +103,6 @@ GetDiskLoad (int Maximum,
guint i;
int max;
- gboolean nvme_diskstats;
guint64 read, write;
guint64 readdiff, writediff;
@@ -112,7 +111,6 @@ GetDiskLoad (int Maximum,
multiload = g->multiload;
- nvme_diskstats = g_settings_get_boolean (multiload->settings, "diskload-nvme-diskstats");
if(first_call)
{
@@ -121,7 +119,7 @@ GetDiskLoad (int Maximum,
read = write = 0;
- if (nvme_diskstats)
+ if (multiload->nvme_diskstats)
{
FILE *fdr;
char line[255];
@@ -130,6 +128,7 @@ GetDiskLoad (int Maximum,
fdr = fopen("/proc/diskstats", "r");
if (!fdr)
{
+ multiload->nvme_diskstats = FALSE;
g_settings_set_boolean (multiload->settings, "diskload-nvme-diskstats", FALSE);
return;
}