Bug #61929
closedDBAL: admin_query() produces wrong error, because it accesses 'TABLE' before check if query can be correctly parsed...
100%
Description
Pseudo:
admin_query($query): // sysext/dbal/Classes/Database/DatabaseConnection.php - line 2863
$parsedQuery = parseSQL($query);
$ORIG_table = $parsedQuery['TABLE']; // << here is the problem!
if (!is_array($parsedQuery)) {
throw new \InvalidArgumentException('ERROR: Query could not be parsed: "' . htmlspecialchars($parsedQuery) . '". Query: "' . htmlspecialchars($query) . '"', 1310027793);
}
Should be:
$parsedQuery = parseSQL($query);
if (!is_array($parsedQuery)) {
throw new \InvalidArgumentException('ERROR: Query could not be parsed: "' . htmlspecialchars($parsedQuery) . '". Query: "' . htmlspecialchars($query) . '"', 1310027793);
}
$ORIG_table = $parsedQuery['TABLE'];
Updated by Gerrit Code Review about 10 years ago
- Status changed from New to Under Review
Patch set 1 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at http://review.typo3.org/32996
Updated by Gerrit Code Review about 10 years ago
Patch set 1 for branch TYPO3_6-2 of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at http://review.typo3.org/33006
Updated by Markus Klein about 10 years ago
- Status changed from Under Review to Resolved
- % Done changed from 0 to 100
Applied in changeset 7a1c0a38bd63d110f9966448e706b2537ba2e1e4.