diff options
Diffstat (limited to 'env-pr8.patch')
-rw-r--r-- | env-pr8.patch | 53 |
1 files changed, 52 insertions, 1 deletions
diff --git a/env-pr8.patch b/env-pr8.patch index 6bcae23..6ace4d9 100644 --- a/env-pr8.patch +++ b/env-pr8.patch @@ -1,7 +1,7 @@ From 58552b8035d4b0a72040f0c8aed91ae849172eda Mon Sep 17 00:00:00 2001 From: Remi Collet <fedora@famillecollet.com> Date: Thu, 1 Dec 2016 17:40:42 +0100 -Subject: [PATCH] fix segfault with 7.1.0, fix #7 +Subject: [PATCH 1/2] fix segfault with 7.1.0, fix #7 --- php7/php_env.c | 2 +- @@ -20,3 +20,54 @@ index 22c19b4..b891ba7 100644 php_env_ini_parser_cb, vars) == FAILURE || ENV_G(parse_err)) { if (ENV_G(parse_err)) { php_error(E_WARNING, "env: parsing '%s' failed", ENV_G(file)); + +From b91c4c1302b6fc8c731072d8d0b4e3eb7275f534 Mon Sep 17 00:00:00 2001 +From: Remi Collet <remi@remirepo.net> +Date: Wed, 19 Feb 2020 09:38:24 +0100 +Subject: [PATCH 2/2] fix multiple definition of 'env_globals' + +--- + php5/php_env.c | 2 -- + php7/php_env.c | 2 -- + php_env.h | 2 ++ + 3 files changed, 2 insertions(+), 4 deletions(-) + +diff --git a/php5/php_env.c b/php5/php_env.c +index 62a231a..a1381df 100644 +--- a/php5/php_env.c ++++ b/php5/php_env.c +@@ -2,8 +2,6 @@ + #include "../php_env.h" + #include "../env.h" + +-ZEND_DECLARE_MODULE_GLOBALS(env) +- + static void php_env_ini_parser_cb(zval *key, zval *value, zval *index, int callback_type, HashTable *ht) /* {{{ */ { + zval *rv; + char *str; +diff --git a/php7/php_env.c b/php7/php_env.c +index b891ba7..b1fa628 100644 +--- a/php7/php_env.c ++++ b/php7/php_env.c +@@ -2,8 +2,6 @@ + #include "../php_env.h" + #include "../env.h" + +-ZEND_DECLARE_MODULE_GLOBALS(env) +- + static void php_env_ini_parser_cb(zval *key, zval *value, zval *index, int callback_type, void *arg) /* {{{ */ { + HashTable *ht = (HashTable*)arg; + char *str; +diff --git a/php_env.h b/php_env.h +index de91d42..8455854 100644 +--- a/php_env.h ++++ b/php_env.h +@@ -44,6 +44,8 @@ ZEND_BEGIN_MODULE_GLOBALS(env) + int parse_err; + ZEND_END_MODULE_GLOBALS(env) + ++ZEND_EXTERN_MODULE_GLOBALS(env) ++ + #ifdef ZTS + #define ENV_G(v) TSRMG(env_globals_id, zend_env_globals *, v) + #else |