Noise: Prevent unittest crash caused by division by zero
[oweals/minetest.git] / src / ban.h
index e35bd0e10e2dc135f3967eceff9ea72dccb80063..35bf10abb8d5ed4015128cbdc9c517b979f6498d 100644 (file)
--- a/src/ban.h
+++ b/src/ban.h
@@ -22,10 +22,10 @@ with this program; if not, write to the Free Software Foundation, Inc.,
 
 #include "util/string.h"
 #include "threading/thread.h"
-#include "threading/mutex.h"
 #include "exceptions.h"
 #include <map>
 #include <string>
+#include <mutex>
 
 class BanManager
 {
@@ -43,10 +43,10 @@ public:
        bool isModified();
 
 private:
-       Mutex m_mutex;
-       std::string m_banfilepath;
+       std::mutex m_mutex;
+       std::string m_banfilepath = "";
        StringMap m_ips;
-       bool m_modified;
+       bool m_modified = false;
 };
 
 #endif