Save assignment if not necessary

This commit is contained in:
Jakub Vrana 2012-04-29 17:54:18 -07:00
parent 9188d21ea3
commit b16bb54219

View file

@ -71,10 +71,10 @@ if (!$error && $_POST) {
if (!$found && $fp && !feof($fp)) {
$query .= fread($fp, 1e5);
} else {
$offset = $pos + strlen($found);
if (!$found && rtrim($query) == "") {
break;
}
$offset = $pos + strlen($found);
if ($found && rtrim($found) != $delimiter) { // find matching quote or comment end
while (preg_match('(' . ($found == '/*' ? '\\*/' : ($found == '[' ? ']' : (ereg('^-- |^#', $found) ? "\n" : preg_quote($found) . "|\\\\."))) . '|$)s', $query, $match, PREG_OFFSET_CAPTURE, $offset)) { //! respect sql_mode NO_BACKSLASH_ESCAPES
$s = $match[0][0];