v1.9.9.6 [SVN]469 - Call-time pass-by-reference has been dep

A TeamSpeak 2 server monitor addon based on gllcTS2, and Ventrilo server monitor

Moderator: mdeshane

v1.9.9.6 [SVN]469 - Call-time pass-by-reference has been dep

Postby AnthonyB » Mon Sep 07, 2009 1:11 pm

In trying to go to the Ventrilo status page I got a couple of the following errors:
Code: Select all
Warning: Call-time pass-by-reference has been deprecated in C:\inetpub\wwwroot\roster\addons\Guildspeak\index.php on line 81

Warning: Call-time pass-by-reference has been deprecated in C:\inetpub\wwwroot\roster\addons\Guildspeak\index.php on line 88

Warning: Call-time pass-by-reference has been deprecated in C:\inetpub\wwwroot\roster\addons\Guildspeak\index.php on line 96


I have allow_call_time_pass_reference = Off in my php.ini as is recommended.

; Whether to enable the ability to force arguments to be passed by reference
; at function call time. This method is deprecated and is likely to be
; unsupported in future versions of PHP/Zend. The encouraged method of
; specifying which arguments should be passed by reference is in the function
; declaration. You're encouraged to try and turn this option Off and make
; sure your scripts work properly with it in order to ensure they will work
; with future versions of the language (you will receive a warning each time
; you use this feature, and the argument will be passed by value instead of by
; reference).
Roster 2.0.2 svn [latest] latest trunk SVN svn [latest] running on IIS7/Windows Server 2008 SP2 | MySQL 5.0.85 | PHP 5.2.10 | Yes, Roster and PHP rocks on IIS! Even run as FastCGI extension!
User avatar
AnthonyB
Gimpy Developer
Gimpy Developer
 
Posts: 346
Joined: Tue Jul 04, 2006 2:44 pm
Location: Sydney, Australia

Re: v1.9.9.6 [SVN]469 - Call-time pass-by-reference has been dep

Postby mdeshane » Wed Sep 09, 2009 1:58 am

That's some of that pretty little php that Ventrilo.com wrote. I'll have to re-write some of it so it works without using the deprecated pass-by-reference method. Maybe turn $vstat into a global, or make it $guildspeak->vstat. Probably opt for the second as some people would prefer not to use globals.
Remember, most of this addons core is the Ventrilo script from ventrilo.com and gllcts2 script heavily modified for Roster templating, configuration, and db. So, it'll probably have lots more bugs to come.

2nd Thought Edit:
Also, you can try to remove the & before $vstat in the function call on those lines. I don't think it should break as I had changed the functions themselves to use &$vstat in the declaration. I believe making it a reference in the function and not in the function call is the appropriate method.
Image
Accounts Addon - Roster v2 User Account Addon

PKC Dev Site - http://dev.pkcomp.net
My Roster Dev Site - http://myroster.dontexist.net
User avatar
mdeshane
Roster AddOn Dev
Roster AddOn Dev
 
Posts: 204
Joined: Sun Dec 10, 2006 4:54 am
Location: Grand Rapids, MI USA
Realm: Khadgar (PvE) - US

Re: v1.9.9.6 [SVN]469 - Call-time pass-by-reference has been dep

Postby AnthonyB » Thu Sep 10, 2009 1:07 pm

Perfect!

Removing the & before the $vstat in those 3 lines removed the errors.

Not sure if it broke anything as I can't get the vent status exe to run triggered via PHP anyway :P
Roster 2.0.2 svn [latest] latest trunk SVN svn [latest] running on IIS7/Windows Server 2008 SP2 | MySQL 5.0.85 | PHP 5.2.10 | Yes, Roster and PHP rocks on IIS! Even run as FastCGI extension!
User avatar
AnthonyB
Gimpy Developer
Gimpy Developer
 
Posts: 346
Joined: Tue Jul 04, 2006 2:44 pm
Location: Sydney, Australia


Return to GuildSpeak

Who is online

Users browsing this forum: No registered users and 0 guests

cron