Bug #69851 [Com]: Can't set env[] variables in php-fpm.conf to String "yes" or "no"
| From: | rainer-phpbugs at 7val dot com | Date: | Wed, 17 Jun 2015 09:08:45 +0000 |
| Subject: | Bug #69851 [Com]: Can't set env[] variables in php-fpm.conf to String "yes" or "no" | ||
| References: | 1 | Groups: | php.bugs |
| Request: | Send a blank email to php-bugs+get-193596@lists.php.net to get a copy of this message | ||
Edit report at https://bugs.php.net/bug.php?id=69851&edit=1
ID: 69851
Comment by: rainer-phpbugs at 7val dot com
Reported by: rainer-phpbugs at 7val dot com
Summary: Can't set env[] variables in php-fpm.conf to String
"yes" or "no"
Status: Open
Type: Bug
Package: FPM related
Operating System: Linux
PHP Version: 5.6.10
Block user comment: N
Private report: N
New Comment:
Apparently, it's necessary to quote the values for env[], i.e.
env[NSS_SDB_USE_CACHE] = "no"
does not convert the string to an empty value and leaves a literal 'no' without the quotes
in the environment variable.
Previous Comments:
------------------------------------------------------------------------
[2015-06-16 16:53:36] rainer-phpbugs at 7val dot com
Description:
------------
Setting
env[NSS_SDB_USE_CACHE] = no
in php-fpm.conf results in a startup error
ERROR: [.../php-fpm.conf:365] empty value
and php-fpm fails to start. The same behaviour is shown for "false" instead of
"no".
Setting
env[NSS_SDB_USE_CACHE] = yes
in php-fpm.conf shows in phpinfo() as
_ENV["NSS_SDB_USE_CACHE"] 1
instead of the expected "yes". "true" has identical results. Other arbitrary
strings, such as "foo" show up unchanged in $_ENV.
Expected result:
----------------
One should be able to assign arbitrary values to environment variables including "yes",
"no", "false" or "true".
Unless security considerations prevent it, allowable values should include whitespace (including
leading and trailing), including line breaks.
------------------------------------------------------------------------
--
Edit this bug report at https://bugs.php.net/bug.php?id=69851&edit=1