[#2317] Warning: mt_rand(): max(-16777217) issue...

13 years 2 months ago - 13 years 2 months ago #153887 by snims
I'm receiving an error similar to the following:
Warning: mt_rand(): max(-16777217) is smaller than min(0) in /<WEBROOT>/components/com_comprofiler/plugin/user/plug_cbpaidsubscriptions/cbpaidsubscriptions.php on line 1358
...in a couple different locations. The above error is displayed when viewing Paid Subscriptions -> Subscriptions, Baskets, Payments, Merchandise, and Donations.
Warning: mt_rand(): max(-16777217) is smaller than min(0) in /<WEBROOT>/components/com_comprofiler/plugin/user/plug_cbpaidsubscriptions/cbpaidsubscriptions.php on line 1260
...is viewed on Paid Subscriptions -> Settings.

For reference:

Output of uname -a:
Linux McArchy 2.6.35.7-linode29 #1 SMP Wed Oct 13 19:06:43 UTC 2010 i686 Intel(R) Xeon(R) CPU 5130 @ 2.00GHz GenuineIntel GNU/Linux
Output of nginx -v:
nginx version: nginx/0.8.54
Output of php -v:
PHP 5.3.5 with Suhosin-Patch (cli) (built: Jan  6 2011 07:33:54) 
Copyright (c) 1997-2009 The PHP Group
Zend Engine v2.3.0, Copyright (c) 1998-2010 Zend Technologies
    with the ionCube PHP Loader v4.0.6, Copyright (c) 2002-2011, by ionCube Ltd.

Please Log in to join the conversation.

13 years 2 months ago #153899 by krileon
Appears to be a calculation bug present in PHP 5.3.5. Have made a bug ticket to further address the issue as the calculation will need to be changed to avoid such issues, sorry for the inconvenience.

#2317


Kyle (Krileon)
Community Builder Team Member
Before posting on forums: Read FAQ thoroughly + Read our Documentation + Search the forums
CB links: Documentation - Localization - CB Quickstart - CB Paid Subscriptions - Add-Ons - Forge
--
If you are a Professional, Developer, or CB Paid Subscriptions subscriber and have a support issue please always post in your respective support forums for best results!
--
If I've missed your support post with a delay of 3 days or greater and are a Professional, Developer, or CBSubs subscriber please send me a private message with your thread and will reply when possible!
--
Please note I am available Monday - Friday from 8:00 AM CST to 4:00 PM CST. I am away on weekends (Saturday and Sunday) and if I've missed your post on or before a weekend after business hours please wait for the next following business day (Monday) and will get to your issue as soon as possible, thank you.
--
My role here is to provide guidance and assistance. I cannot provide custom code for each custom requirement. Please do not inquire me about custom development.

Please Log in to join the conversation.

13 years 2 months ago #153903 by snims
Will that error affect the usage of CBSubs in any way? Seems silly for me to ask because I'm the one with the error, but I just installed it and haven't had time to use it before noticing the error.

Please Log in to join the conversation.

Moderators: beatnantkrileon
Time to create page: 0.272 seconds

Facebook Twitter LinkedIn