1.1 --- a/core/ConVarManager.cpp Mon Oct 15 19:18:08 2007 +0000
1.2 +++ b/core/ConVarManager.cpp Mon Oct 15 19:37:14 2007 +0000
1.3 @@ -228,13 +228,14 @@
1.4 /* If convar was created by SourceMod plugin... */
1.5 if (info->sourceMod)
1.6 {
1.7 + /* Then unlink it from SourceMM */
1.8 + g_SMAPI->UnregisterConCommandBase(g_PLAPI, pConVar);
1.9 +
1.10 /* Delete string allocations */
1.11 delete [] pConVar->GetName();
1.12 delete [] pConVar->GetDefault();
1.13 delete [] pConVar->GetHelpText();
1.14 -
1.15 - /* Then unlink it from SourceMM */
1.16 - g_SMAPI->UnregisterConCommandBase(g_PLAPI, pConVar);
1.17 + delete pConVar;
1.18 }
1.19 }
1.20