From 2111734d7c23e5ecc8f667fa2a85415790e9ca4a Mon Sep 17 00:00:00 2001 From: Roman Kelesidis Date: Tue, 28 Nov 2023 22:52:40 +0700 Subject: [PATCH] Updated --- bt/includes/init_tr.php | 2 +- common.php | 2 +- library/attach_mod/posting_attachments.php | 2 +- library/includes/cache/memcache.php | 2 +- library/includes/cache/redis.php | 2 +- library/includes/cache/sqlite.php | 4 ++-- library/includes/core/mysql.php | 6 +++--- library/includes/datastore/memcache.php | 2 +- library/includes/datastore/redis.php | 2 +- 9 files changed, 12 insertions(+), 12 deletions(-) diff --git a/bt/includes/init_tr.php b/bt/includes/init_tr.php index d743cd9a..420bac5f 100644 --- a/bt/includes/init_tr.php +++ b/bt/includes/init_tr.php @@ -133,7 +133,7 @@ class sql_db $this->log_error(); if (DBG_LOG_TRACKER) { - dbg_log("Could not connect to {$this->engine} server '{$this->cfg['dbhost']}'", "{$this->cfg['dbhost']}-DB-connect-FAIL_" . time()); + dbg_log("Could not connect to {$this->engine} server '{$this->cfg['dbhost']}'", "{$this->cfg['dbhost']}-DB-connect-FAIL_" . TIMENOW); } } diff --git a/common.php b/common.php index e5b1ba27..088a1e57 100644 --- a/common.php +++ b/common.php @@ -475,7 +475,7 @@ function dbg_log ($str, $file) { if (!DBG_LOG_TRACKER && !DBG_LOG) return false; $dir = (defined('IN_TRACKER') ? 'dbg_tr/' : 'dbg_bb/') . date('m-d_H') .'/'; - return bb_log($str, $dir . clean_filename($file) . '_' . time()); + return bb_log($str, $dir . clean_filename($file) . '_' . TIMENOW); } function log_get ($file = '', $prepend_str = false) diff --git a/library/attach_mod/posting_attachments.php b/library/attach_mod/posting_attachments.php index a412197f..c3e6aef2 100644 --- a/library/attach_mod/posting_attachments.php +++ b/library/attach_mod/posting_attachments.php @@ -985,7 +985,7 @@ class attach_parent $this->attach_filename = preg_replace('#([\xC2\xC3])([\x80-\xBF])#', 'chr(ord(\'$1\')<<6&0xC0|ord(\'$2\')&0x3F)', $this->attach_filename); $this->attach_filename = rawurlencode($this->attach_filename); $this->attach_filename = preg_replace("/(%[0-9A-F]{1,2})/i", '', $this->attach_filename); - $this->attach_filename = trim($this->attach_filename . time()); + $this->attach_filename = trim($this->attach_filename . '_' . TIMENOW); } $this->attach_filename = str_replace(array('&','&',' '), '_', $this->attach_filename); $this->attach_filename = str_replace('php', '_php_', $this->attach_filename); diff --git a/library/includes/cache/memcache.php b/library/includes/cache/memcache.php index bedf176a..284f1d68 100644 --- a/library/includes/cache/memcache.php +++ b/library/includes/cache/memcache.php @@ -44,7 +44,7 @@ class cache_memcache extends cache_common if (DBG_LOG) { - dbg_log($con_error, "{$this->engine}-CACHE-connect-FAIL_" . time()); + dbg_log($con_error, "{$this->engine}-CACHE-connect-FAIL_" . TIMENOW); } die($con_error); diff --git a/library/includes/cache/redis.php b/library/includes/cache/redis.php index d38a8930..d25a41d4 100644 --- a/library/includes/cache/redis.php +++ b/library/includes/cache/redis.php @@ -44,7 +44,7 @@ class cache_redis extends cache_common if (DBG_LOG) { - dbg_log($con_error, "{$this->engine}-CACHE-connect-FAIL_" . time()); + dbg_log($con_error, "{$this->engine}-CACHE-connect-FAIL_" . TIMENOW); } die($con_error); diff --git a/library/includes/cache/sqlite.php b/library/includes/cache/sqlite.php index 0fb7867a..e997b1b6 100644 --- a/library/includes/cache/sqlite.php +++ b/library/includes/cache/sqlite.php @@ -157,7 +157,7 @@ class sqlite_common extends cache_common if (DBG_LOG) { - dbg_log($create_error, "{$this->engine}-CACHE-mkdir-FAIL_" . time()); + dbg_log($create_error, "{$this->engine}-CACHE-mkdir-FAIL_" . TIMENOW); } die($create_error); @@ -183,7 +183,7 @@ class sqlite_common extends cache_common if (DBG_LOG) { - dbg_log($con_error, "{$this->engine}-CACHE-connect-FAIL_" . time()); + dbg_log($con_error, "{$this->engine}-CACHE-connect-FAIL_" . TIMENOW); } die($con_error); diff --git a/library/includes/core/mysql.php b/library/includes/core/mysql.php index 1ac78d82..93037174 100644 --- a/library/includes/core/mysql.php +++ b/library/includes/core/mysql.php @@ -76,7 +76,7 @@ class sql_db $charset_error = "Could not set charset '{$this->cfg['charset']}'"; if (DBG_LOG) { - dbg_log($charset_error, "{$this->cfg['charset']}-DB-charset-FAIL_" . time()); + dbg_log($charset_error, "{$this->cfg['charset']}-DB-charset-FAIL_" . TIMENOW); } die($charset_error); } @@ -105,7 +105,7 @@ class sql_db $con_error = "Could not connect to {$this->engine} server $server"; if (DBG_LOG) { - dbg_log($con_error, "{$this->cfg['dbhost']}-DB-connect-FAIL_" . time()); + dbg_log($con_error, "{$this->cfg['dbhost']}-DB-connect-FAIL_" . TIMENOW); } die($con_error); } @@ -132,7 +132,7 @@ class sql_db $select_error = "Could not select database $db_name"; if (DBG_LOG) { - dbg_log($select_error, "{$this->cfg['dbname']}-DB-select-FAIL_" . time()); + dbg_log($select_error, "{$this->cfg['dbname']}-DB-select-FAIL_" . TIMENOW); } die($select_error); } diff --git a/library/includes/datastore/memcache.php b/library/includes/datastore/memcache.php index 26a2c86c..9e677c96 100644 --- a/library/includes/datastore/memcache.php +++ b/library/includes/datastore/memcache.php @@ -43,7 +43,7 @@ class datastore_memcache extends datastore_common if (DBG_LOG) { - dbg_log($con_error, "{$this->engine}-CACHE-connect-FAIL_" . time()); + dbg_log($con_error, "{$this->engine}-CACHE-connect-FAIL_" . TIMENOW); } die($con_error); diff --git a/library/includes/datastore/redis.php b/library/includes/datastore/redis.php index 7298e5b2..b0a9291e 100644 --- a/library/includes/datastore/redis.php +++ b/library/includes/datastore/redis.php @@ -43,7 +43,7 @@ class datastore_redis extends datastore_common if (DBG_LOG) { - dbg_log($con_error, "{$this->engine}-CACHE-connect-FAIL_" . time()); + dbg_log($con_error, "{$this->engine}-CACHE-connect-FAIL_" . TIMENOW); } die($con_error);