From a5c75761c2dcecbfbab5343d7fce54d7278f9e23 Mon Sep 17 00:00:00 2001 From: Stig Venaas Date: Fri, 3 Nov 2000 07:20:35 +0000 Subject: [PATCH] Fixed memory leak in array_diff and array_intersect, was introduced with last change. --- ext/standard/array.c | 2 -- 1 file changed, 2 deletions(-) diff --git a/ext/standard/array.c b/ext/standard/array.c index 1a558a07fd..8e6b55ab9b 100644 --- a/ext/standard/array.c +++ b/ext/standard/array.c @@ -2288,7 +2288,6 @@ PHP_FUNCTION(array_intersect) efree(args); WRONG_PARAM_COUNT; } - array_init(return_value); /* for each argument, create and sort list with pointers to the hash buckets */ lists = (Bucket ***)emalloc(argc * sizeof(Bucket **)); ptrs = (Bucket ***)emalloc(argc * sizeof(Bucket **)); @@ -2394,7 +2393,6 @@ PHP_FUNCTION(array_diff) efree(args); WRONG_PARAM_COUNT; } - array_init(return_value); /* for each argument, create and sort list with pointers to the hash buckets */ lists = (Bucket ***)emalloc(argc * sizeof(Bucket **)); ptrs = (Bucket ***)emalloc(argc * sizeof(Bucket **)); -- 2.50.1