fix #17779 - PHP 8 numeric operation (#17827)

Fixes #17779

php8 throws exception in spite of @ symbol so work around it

Signed-off-by: Alex Liberman <alex@zoosmart.us>
This commit is contained in:
aliber4079 2022-11-05 12:46:58 -05:00 committed by GitHub
parent 04042517a5
commit c958e27bfa
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -738,9 +738,12 @@ class Results
: 'false') . ';"';
$hasRealEndInput = $isInnodb && $this->properties['unlim_num_rows'] > $GLOBALS['cfg']['MaxExactCount'];
$posLast = @((int) ceil(
(int) $this->properties['unlim_num_rows'] / $_SESSION['tmpval']['max_rows']
) - 1) * intval($_SESSION['tmpval']['max_rows']);
$posLast = 0;
if (is_numeric($_SESSION['tmpval']['max_rows'])) {
$posLast = @((int) ceil(
(int) $this->properties['unlim_num_rows'] / $_SESSION['tmpval']['max_rows']
) - 1) * intval($_SESSION['tmpval']['max_rows']);
}
$hiddenFields = [
'db' => $this->properties['db'],