File tree Expand file tree Collapse file tree 2 files changed +9
-1
lines changed Expand file tree Collapse file tree 2 files changed +9
-1
lines changed Original file line number Diff line number Diff line change @@ -130,6 +130,10 @@ RESULT=`docker run --rm -e PHP_INI_ERROR_REPORTING="E_ERROR | E_WARNING" thecodi
130
130
RESULT=` docker run --rm -e PHP_INI_SESSION__SAVE_PATH=" tcp://localhost?auth=yourverycomplex\" passwordhere" thecodingmachine/php:${PHP_VERSION} -${BRANCH} -slim-${BRANCH_VARIANT} php -i | grep " session.save_path" `
131
131
[[ " $RESULT " = " session.save_path => tcp://localhost?auth=yourverycomplex\" passwordhere => tcp://localhost?auth=yourverycomplex\" passwordhere" ]]
132
132
133
+ # Tests that the SMTP parameter is set in uppercase
134
+ RESULT=` docker run --rm -e PHP_INI_SMTP=" 192.168.0.1" thecodingmachine/php:${PHP_VERSION} -${BRANCH} -slim-${BRANCH_VARIANT} php -i | grep " ^SMTP" `
135
+ [[ " $RESULT " = " SMTP => 192.168.0.1 => 192.168.0.1" ]]
136
+
133
137
# Tests that environment variables are passed to startup scripts when UID is set
134
138
RESULT=` docker run --rm -e FOO=" bar" -e STARTUP_COMMAND_1=" env" -e UID=0 thecodingmachine/php:${PHP_VERSION} -${BRANCH} -slim-${BRANCH_VARIANT} sleep 1 | grep " FOO" `
135
139
[[ " $RESULT " = " FOO=bar" ]]
Original file line number Diff line number Diff line change 10
10
11
11
foreach ($ _SERVER as $ key => $ value ) {
12
12
if (strpos ($ key , 'PHP_INI_ ' ) === 0 ) {
13
- $ iniParam = strtolower (substr ($ key , 8 ));
13
+ $ iniParam = substr ($ key , 8 );
14
+ if ($ iniParam !== 'SMTP ' ) {
15
+ // SMTP is the only php.ini parameter that contains uppercase letters (!)
16
+ $ iniParam = strtolower ($ iniParam );
17
+ }
14
18
$ iniParam = str_replace ('__ ' , '. ' , $ iniParam );
15
19
// Let's protect the value if this is a string.
16
20
if (!is_numeric ($ value ) && $ iniParam !== 'error_reporting ' ) {
You can’t perform that action at this time.
0 commit comments