Merge pull request #432 from Exile37/bugfix/logfile-regex

Incorrect log file rotation regex
This commit is contained in:
Yuriy Pikhtarev 2017-07-29 09:15:46 +03:00 committed by GitHub
commit 78080dea32
2 changed files with 2 additions and 2 deletions

View file

@ -263,7 +263,7 @@ function file_write($str, $file, $max_size = LOG_MAX_SIZE, $lock = true, $replac
if ($max_size && file_exists($file) && filesize($file) >= $max_size) { if ($max_size && file_exists($file) && filesize($file) >= $max_size) {
$old_name = $file; $old_name = $file;
$ext = ''; $ext = '';
if (preg_match('#^(.+)(\.[^\\/]+)$#', $file, $matches)) { if (preg_match('#^(.+)(\.[^\\\/]+)$#', $file, $matches)) {
$old_name = $matches[1]; $old_name = $matches[1];
$ext = $matches[2]; $ext = $matches[2];
} }

View file

@ -29,7 +29,7 @@ if (!defined('BB_ROOT')) {
$domain_name = 'torrentpier.com'; // enter here your primary domain name of your site $domain_name = 'torrentpier.com'; // enter here your primary domain name of your site
$domain_name = (!empty($_SERVER['SERVER_NAME'])) ? $_SERVER['SERVER_NAME'] : $domain_name; $domain_name = (!empty($_SERVER['SERVER_NAME'])) ? $_SERVER['SERVER_NAME'] : $domain_name;
$domain_ssl = true; $domain_ssl = false;
$bb_cfg = []; $bb_cfg = [];