aboutsummaryrefslogtreecommitdiffstats
path: root/phpBB/phpbb/cache
diff options
context:
space:
mode:
authorJoas Schilling <nickvergessen@gmx.de>2014-10-01 11:39:35 +0200
committerJoas Schilling <nickvergessen@gmx.de>2014-10-01 11:39:35 +0200
commitb9226c6877a8e5a633988fcc6e1474045f8a5e86 (patch)
tree8a0dbf2502da4ac976ae418c4897cff3e156c5c4 /phpBB/phpbb/cache
parentdceb334a0c495bb76b9f8309b950eb9b3875b4c1 (diff)
parent40cd7570e6f4da7cc60d83a3e99c72a2fb99e3f7 (diff)
downloadforums-b9226c6877a8e5a633988fcc6e1474045f8a5e86.tar
forums-b9226c6877a8e5a633988fcc6e1474045f8a5e86.tar.gz
forums-b9226c6877a8e5a633988fcc6e1474045f8a5e86.tar.bz2
forums-b9226c6877a8e5a633988fcc6e1474045f8a5e86.tar.xz
forums-b9226c6877a8e5a633988fcc6e1474045f8a5e86.zip
Merge branch 'develop-ascraeus' into develop
Diffstat (limited to 'phpBB/phpbb/cache')
-rw-r--r--phpBB/phpbb/cache/driver/memory.php16
1 files changed, 2 insertions, 14 deletions
diff --git a/phpBB/phpbb/cache/driver/memory.php b/phpBB/phpbb/cache/driver/memory.php
index 0cef9c3483..add87b9bfa 100644
--- a/phpBB/phpbb/cache/driver/memory.php
+++ b/phpBB/phpbb/cache/driver/memory.php
@@ -208,24 +208,12 @@ abstract class memory extends \phpbb\cache\driver\base
// determine which tables this query belongs to
// Some queries use backticks, namely the get_database_size() query
// don't check for conformity, the SQL would error and not reach here.
- if (!preg_match_all('/(?:FROM \\(?(`?\\w+`?(?: \\w+)?(?:, ?`?\\w+`?(?: \\w+)?)*)\\)?)|(?:JOIN (`?\\w+`?(?: \\w+)?))/', $query, $regs, PREG_SET_ORDER))
+ if (!preg_match('/FROM \\(?(`?\\w+`?(?: \\w+)?(?:, ?`?\\w+`?(?: \\w+)?)*)\\)?/', $query, $regs))
{
// Bail out if the match fails.
return $query_result;
}
-
- $tables = array();
- foreach ($regs as $match)
- {
- if ($match[0][0] == 'F')
- {
- $tables = array_merge($tables, array_map('trim', explode(',', $match[1])));
- }
- else
- {
- $tables[] = $match[2];
- }
- }
+ $tables = array_map('trim', explode(',', $regs[1]));
foreach ($tables as $table_name)
{