From 138c3bc76e7f7ba8bb9e10de870eda97237fb35a Mon Sep 17 00:00:00 2001 From: Kevin Ruland Date: Tue, 31 Jan 2006 16:38:14 +0000 Subject: [PATCH] Fix memory leak in GetModule. git-svn-id: https://swig.svn.sourceforge.net/svnroot/swig/trunk/SWIG@8659 626c5289-ae23-0410-ae9c-e8d60b6d4f22 --- Lib/php4/php4run.swg | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/Lib/php4/php4run.swg b/Lib/php4/php4run.swg index 1620dea9e..ec19e5506 100644 --- a/Lib/php4/php4run.swg +++ b/Lib/php4/php4run.swg @@ -190,7 +190,8 @@ static swig_module_info *SWIG_Php4_GetModule() { ret = (swig_module_info *) pointer->value.lval; } } - return 0; + FREE_ZVAL(pointer); + return ret; } static void SWIG_Php4_SetModule(swig_module_info *pointer) {