memory leak(off by 1 bug)

git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@5774 b3059339-0415-0410-9bf9-f77b7e298cf2
This commit is contained in:
iive 2002-04-21 16:56:19 +00:00
parent 534b2cb3f5
commit 08465f819d
1 changed files with 1 additions and 1 deletions

View File

@ -71,7 +71,7 @@ int add_plugin(int i,char* cfg){
// Is this the last iteration or just another plugin
if(cfg[cnt]=='\0'){
ao_plugin_local_data.plugins=malloc((i+1)*sizeof(ao_plugin_functions_t*));
ao_plugin_local_data.plugins=malloc((i+2)*sizeof(ao_plugin_functions_t*));
if(ao_plugin_local_data.plugins){
ao_plugin_local_data.plugins[i+1]=NULL;
// Find the plugin matching the cfg string name