diff --git a/src/system/hddstat.cpp b/src/system/hddstat.cpp index 37318e795..979dedf24 100644 --- a/src/system/hddstat.cpp +++ b/src/system/hddstat.cpp @@ -41,10 +41,10 @@ #include #include -static cHddStat *instance = NULL; - cHddStat *cHddStat::getInstance(void) { + static cHddStat *instance = NULL; + if (!instance) instance = new cHddStat; return instance;