diff --git a/Code/Mantid/Framework/MDAlgorithms/src/LoadMD.cpp b/Code/Mantid/Framework/MDAlgorithms/src/LoadMD.cpp index 5b5d3b02c1d2..e9736c335496 100644 --- a/Code/Mantid/Framework/MDAlgorithms/src/LoadMD.cpp +++ b/Code/Mantid/Framework/MDAlgorithms/src/LoadMD.cpp @@ -366,7 +366,10 @@ namespace Mantid if(!box)continue; if(BoxEventIndex[2*i+1]>0) // Load in memory NOT using the file as the back-end, + { + boxTree[i]->reserveMemoryForLoad(BoxEventIndex[2*i+1]); boxTree[i]->loadAndAddFrom(loader.get(),BoxEventIndex[2*i],static_cast(BoxEventIndex[2*i+1])); + } } loader->closeFile();