-
-
Notifications
You must be signed in to change notification settings - Fork 2.6k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Excluding IPs doesn't work on php7 #10373
Comments
Thanks @andrzejewsky for the bug report! If you can help, consider submitting a unit test reproducing the bug on PHP7 👍 |
Tracked down this bug to an invalid range (i.e., missing the suffix). See PR for fix and updated test. |
Hi @andrzejewsky |
@mattab - I have tested that change and it appears to resolve this issue for me. |
thanks @alex-whitney created #15124 |
Las time when we were testing Piwik with the newest version of PHP. Actually, everything looks promising except small error which arose during archivization process.
This problem is about bit-shifting in this class: https://github.com/piwik/component-network/blob/0.2.0/src/IPUtils.php.
Look at line https://github.com/piwik/component-network/blob/0.2.0/src/IPUtils.php#L182
Sometimes variable
$n
is a negative number and in the PHP7 it will throw an exception because this version of PHP introduced exceptions instead of fatal errors, null values etc.small example:
The text was updated successfully, but these errors were encountered: