diff --git a/source/plugin/PluginDataFactory.cpp b/source/plugin/PluginDataFactory.cpp index 50db509..c79185e 100644 --- a/source/plugin/PluginDataFactory.cpp +++ b/source/plugin/PluginDataFactory.cpp @@ -67,31 +67,23 @@ std::vector PluginDataFactory::loadDir(const std::string &path, MEMH std::optional PluginDataFactory::load(const std::string &filename, MEMHeapHandle heapHandle) { // open the file: - DEBUG_FUNCTION_LINE(); std::ifstream file(filename, std::ios::binary); - DEBUG_FUNCTION_LINE(); if (!file.is_open()) { DEBUG_FUNCTION_LINE("Failed to open %s", filename.c_str()); return std::nullopt; } // Stop eating new lines in binary mode!!! file.unsetf(std::ios::skipws); - DEBUG_FUNCTION_LINE(); // get its size: std::streampos fileSize; - DEBUG_FUNCTION_LINE(); file.seekg(0, std::ios::end); fileSize = file.tellg(); file.seekg(0, std::ios::beg); - DEBUG_FUNCTION_LINE(); - std::vector vBuffer; vBuffer.reserve(fileSize); - - DEBUG_FUNCTION_LINE(); // read the data: vBuffer.insert(vBuffer.begin(), std::istream_iterator(file),