diff --git a/amxmodx/CPlugin.cpp b/amxmodx/CPlugin.cpp index d7a1bbfc..de8327f3 100755 --- a/amxmodx/CPlugin.cpp +++ b/amxmodx/CPlugin.cpp @@ -541,29 +541,26 @@ void CPluginMngr::CacheAndLoadModules(const char *plugin) CVector expects; CVector defaults; + CStack delstack; for (int i=0; icmd == LibCmd_ForceLib) { RunLibCommand(dc); - delete dc; } else if ( (dc->cmd == LibCmd_ExpectClass) || (dc->cmd == LibCmd_ExpectLib) ) { expects.push_back(dc); } else if (dc->cmd == LibCmd_DefaultLib) { defaults.push_back(dc); - } else { - delete dc; } - } else { - delete dc; } } } @@ -571,12 +568,19 @@ void CPluginMngr::CacheAndLoadModules(const char *plugin) for (size_t i=0; i