Skip to content

Commit 515de02

Browse files
author
Till Brehm
committed
- Removed SQL mode check from installer. The check is not needed anymore.
- Fixed #5027 add support for PHP 7.1 and 7.2 on nginx servers in apps vhost. - suppress some warnings in simplepie.inc.php
1 parent 165e6af commit 515de02

File tree

3 files changed

+15
-5
lines changed

3 files changed

+15
-5
lines changed

install/lib/installer_base.lib.php

Lines changed: 8 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -225,14 +225,14 @@ public function configure_database() {
225225
global $conf;
226226

227227
//* check sql-mode
228-
$check_sql_mode = $this->db->queryOneRecord("SELECT @@sql_mode");
228+
/*$check_sql_mode = $this->db->queryOneRecord("SELECT @@sql_mode");
229229
230230
if ($check_sql_mode['@@sql_mode'] != '' && $check_sql_mode['@@sql_mode'] != 'NO_ENGINE_SUBSTITUTION') {
231231
echo "Wrong SQL-mode. You should use NO_ENGINE_SUBSTITUTION. Add\n\n";
232232
echo " sql-mode=\"NO_ENGINE_SUBSTITUTION\"\n\n";
233233
echo"to the mysqld-section in your mysql-config on this server and restart mysqld afterwards\n";
234234
die();
235-
}
235+
}*/
236236

237237
$unwanted_sql_plugins = array('validate_password');
238238
$sql_plugins = $this->db->queryAllRecords("SELECT plugin_name FROM information_schema.plugins WHERE plugin_status='ACTIVE' AND plugin_name IN ?", $unwanted_sql_plugins);
@@ -2093,7 +2093,12 @@ public function configure_apps_vhost() {
20932093
$content = str_replace('{fpm_socket}', $fpm_socket, $content);
20942094
$content = str_replace('{cgi_socket}', $cgi_socket, $content);
20952095

2096-
if(file_exists('/var/run/php5-fpm.sock') || file_exists('/var/run/php/php7.0-fpm.sock')){
2096+
if( file_exists('/var/run/php5-fpm.sock')
2097+
|| file_exists('/var/run/php/php7.0-fpm.sock')
2098+
|| file_exists('/var/run/php/php7.1-fpm.sock')
2099+
|| file_exists('/var/run/php/php7.2-fpm.sock')
2100+
|| file_exists('/var/run/php/php7.3-fpm.sock')
2101+
){
20972102
$use_tcp = '#';
20982103
$use_socket = '';
20992104
} else {

interface/lib/classes/simplepie.inc.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13338,7 +13338,7 @@ function date_w3cdtf($date)
1333813338
}
1333913339

1334013340
// Convert the number of seconds to an integer, taking decimals into account
13341-
$second = round($match[6] + $match[7] / pow(10, strlen($match[7])));
13341+
$second = @round($match[6] + $match[7] / @pow(10, strlen($match[7])));
1334213342

1334313343
return gmmktime($match[4], $match[5], $second, $match[2], $match[3], $match[1]) - $timezone;
1334413344
}

server/plugins-available/apps_vhost_plugin.inc.php

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -169,7 +169,12 @@ function update($event_name, $data) {
169169
//$content = str_replace('{fpm_port}', $web_config['php_fpm_start_port']+1, $content);
170170
$content = str_replace('{fpm_socket}', $fpm_socket, $content);
171171
$content = str_replace('{cgi_socket}', $cgi_socket, $content);
172-
if(file_exists('/var/run/php5-fpm.sock') || file_exists('/var/run/php/php7.0-fpm.sock')){
172+
if( file_exists('/var/run/php5-fpm.sock')
173+
|| file_exists('/var/run/php/php7.0-fpm.sock')
174+
|| file_exists('/var/run/php/php7.1-fpm.sock')
175+
|| file_exists('/var/run/php/php7.2-fpm.sock')
176+
|| file_exists('/var/run/php/php7.3-fpm.sock')
177+
){
173178
$use_tcp = '#';
174179
$use_socket = '';
175180
} else {

0 commit comments

Comments
 (0)