Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:51139 Return-Path: Mailing-List: contact internals-help@lists.php.net; run by ezmlm Delivered-To: mailing list internals@lists.php.net Received: (qmail 34256 invoked from network); 27 Dec 2010 22:50:34 -0000 Received: from unknown (HELO lists.php.net) (127.0.0.1) by localhost with SMTP; 27 Dec 2010 22:50:34 -0000 Authentication-Results: pb1.pair.com header.from=cr@cristianrodriguez.net; sender-id=pass Authentication-Results: pb1.pair.com smtp.mail=cr@cristianrodriguez.net; spf=pass; sender-id=pass Received-SPF: pass (pb1.pair.com: domain cristianrodriguez.net designates 209.85.218.42 as permitted sender) X-PHP-List-Original-Sender: cr@cristianrodriguez.net X-Host-Fingerprint: 209.85.218.42 mail-yi0-f42.google.com Received: from [209.85.218.42] ([209.85.218.42:61204] helo=mail-yi0-f42.google.com) by pb1.pair.com (ecelerity 2.1.1.9-wez r(12769M)) with ESMTP id 88/25-05779-938191D4 for ; Mon, 27 Dec 2010 17:50:33 -0500 Received: by yia28 with SMTP id 28so1694925yia.29 for ; Mon, 27 Dec 2010 14:50:30 -0800 (PST) Received: by 10.91.45.4 with SMTP id x4mr3602069agj.77.1293490230794; Mon, 27 Dec 2010 14:50:30 -0800 (PST) Received: from localhost.localdomain ([190.162.40.226]) by mx.google.com with ESMTPS id b27sm18179576ana.8.2010.12.27.14.50.28 (version=TLSv1/SSLv3 cipher=RC4-MD5); Mon, 27 Dec 2010 14:50:30 -0800 (PST) Sender: =?UTF-8?Q?Cristian_Rodr=C3=ADguez?= To: internals@lists.php.net Cc: =?UTF-8?q?Cristian=20Rodr=C3=ADguez?= Date: Mon, 27 Dec 2010 19:50:45 -0300 Message-ID: <1293490245-16963-1-git-send-email-cristian.rodriguez@opensuse.org> X-Mailer: git-send-email 1.7.3.4 MIME-Version: 1.0 Content-Type: multipart/mixed; boundary="------------1.7.3.4" Subject: =?UTF-8?q?=5BPATCH=5D=20fix=20memory=20leak=20in=20fpm=5Fconf=5Fset=5Farray=28=29?= From: cristian.rodriguez@opensuse.org (=?UTF-8?q?Cristian=20Rodr=C3=ADguez?=) --------------1.7.3.4 Content-Type: text/plain; charset=UTF-8; format=fixed Content-Transfer-Encoding: 8bit Signed-off-by: Cristian Rodríguez --- sapi/fpm/fpm/fpm_conf.c | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-) --------------1.7.3.4 Content-Type: text/x-patch; name="0001-fix-memory-leak-in-fpm_conf_set_array.patch" Content-Transfer-Encoding: 8bit Content-Disposition: attachment; filename="0001-fix-memory-leak-in-fpm_conf_set_array.patch" diff --git a/sapi/fpm/fpm/fpm_conf.c b/sapi/fpm/fpm/fpm_conf.c index 5d6fe77..5bd7e7c 100644 --- a/sapi/fpm/fpm/fpm_conf.c +++ b/sapi/fpm/fpm/fpm_conf.c @@ -318,7 +318,7 @@ static char *fpm_conf_set_array(zval *key, zval *value, void **config, int conve if (convert_to_bool) { char *err = fpm_conf_set_boolean(value, &subconf, 0); - if (err) return err; + if (err) { free(kv); return err;} kv->value = strdup(b ? "On" : "Off"); } else { kv->value = strdup(Z_STRVAL_P(value)); --------------1.7.3.4--