Commit 9eb014a5 authored by Benjamin Nolan's avatar Benjamin Nolan Committed by Steve Müller

Issue #2313 - Check for $orderByPos === false to prevent an infinite loop

parent 0f7bf0ce
......@@ -1228,8 +1228,12 @@ class SQLServerPlatform extends AbstractPlatform
$offset = 0;
while ($count-- > 0) {
$qLen = strlen($query);
$orderByPos = stripos($query, " ORDER BY", $offset);
if ($orderByPos === false) {
break;
}
$qLen = strlen($query);
$parenCount = 0;
$currentPosition = $orderByPos;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment