]> git.sesse.net Git - stockfish/blobdiff - src/material.cpp
Don't allocate MAX_THREADS hash tables if not necessary
[stockfish] / src / material.cpp
index ef7428a3a989586ceb87dfa32ce082aa08712f93..add0f32bc29509844997880cc2ffdd3aa9c67cf9 100644 (file)
@@ -85,7 +85,7 @@ namespace {
 
 /// MaterialInfoTable c'tor and d'tor allocate and free the space for Endgames
 
-void MaterialInfoTable::init() { Base::init(); funcs = new Endgames(); }
+void MaterialInfoTable::init() { Base::init(); if (!funcs) funcs = new Endgames(); }
 MaterialInfoTable::~MaterialInfoTable() { delete funcs; }