]> git.lizzy.rs Git - minetest.git/blobdiff - src/itemgroup.h
Dungeongen: Fix out-of-voxelmanip access segfault
[minetest.git] / src / itemgroup.h
index 69678064fe606fe3583bc7b9b1e886b35d67460a..f91ccc221e3eea497a1abf5ef57066844ade4ef5 100644 (file)
@@ -20,16 +20,15 @@ with this program; if not, write to the Free Software Foundation, Inc.,
 #ifndef ITEMGROUP_HEADER
 #define ITEMGROUP_HEADER
 
-#include "irrlichttypes_extrabloated.h"
 #include <string>
-#include <map>
+#include "util/cpp11_container.h"
 
-typedef std::map<std::string, int> ItemGroupList;
+typedef UNORDERED_MAP<std::string, int> ItemGroupList;
 
 static inline int itemgroup_get(const ItemGroupList &groups,
                const std::string &name)
 {
-       std::map<std::string, int>::const_iterator i = groups.find(name);
+       ItemGroupList::const_iterator i = groups.find(name);
        if(i == groups.end())
                return 0;
        return i->second;