From 1d6b173e87603bb55ebec8f8de2f2f57fe6921b5 Mon Sep 17 00:00:00 2001 From: David Anderson Date: Thu, 28 Jul 2005 18:00:40 +0000 Subject: [PATCH] Fixed a bug where bad plugins could crash --- amxmodx/CPlugin.cpp | 1 + 1 file changed, 1 insertion(+) diff --git a/amxmodx/CPlugin.cpp b/amxmodx/CPlugin.cpp index 37a4693a..4f29b639 100755 --- a/amxmodx/CPlugin.cpp +++ b/amxmodx/CPlugin.cpp @@ -161,6 +161,7 @@ CPluginMngr::CPlugin::CPlugin(int i, const char* p,const char* n, char* e, int d char file[256]; char* path = build_pathname_r(file, sizeof(file)-1, "%s/%s",p,n); code = 0; + memset(&amx, 0, sizeof(AMX)); int err = load_amxscript(&amx,&code,path,e, d); if ( err == AMX_ERR_NONE ) {