News:

SMF 2.1.4 has been released! Take it for a spin! Read more.

Main Menu

optimus_buffer() error

Started by Sir Osis of Liver, December 16, 2018, 11:39:47 PM

Previous topic - Next topic

Sir Osis of Liver

Server crashed, forum restored to different server from backup by host.  Getting a ton of these errors, all guests/users, all links -



2: Parameter 1 to optimus_buffer() expected to be a reference, value given



optimus_buffer() is not in core code, don't recognize it as mod code.  Forum appears to be working.

Version Information:
Forum version: SMF 2.0.15 (more detailed)
Current SMF version: SMF 2.0.15
GD version: bundled (2.1.0 compatible)
Database Server: MySQL
MySQL version: 5.7.24
PHP: 7.1.25
Server version: Apache

Ashes and diamonds, foe and friend,
 we were all equal in the end.

                                     - R. Waters

br360

I haven't used it so not 100%, but it looks like this is the mod that could be causing the issue- https://custom.simplemachines.org/mods/index.php?mod=2659

Arantor

If you look at the function definition, the first variable in it will have a & before the $, remove it.

Sir Osis of Liver

Optimus mod is not installed.   

Which function definition?
Ashes and diamonds, foe and friend,
 we were all equal in the end.

                                     - R. Waters

Arantor

Well, it sure looks like it. As for the function definition, how about searching the code for "optimus_buffer", the function it is complaining about which is clearly available even if the mod claims to not be installed.

Sir Osis of Liver

Haven't been able to reestablish ftp access, so am limited to file manager.  Search for "optimus" returns .css file only.  /Packages contains Optimus Brave dated Feb 2014, and there's a PM backup for the mod same date.  It's not currently listed in PM.  This forum is a mess, some mods were installed over a dozen times.  Host migrated it to "upgraded server" couple weeks ago, caused all kinds of problems.  Cleaned it up, "upgraded server" crashed over weekend, host installed backup to yet another server, that's when this error showed up.  Owner does not want to do clean install, but that's obviously what's needed.  Forum is running, but it's logged 36,000 errors since last night.
Ashes and diamonds, foe and friend,
 we were all equal in the end.

                                     - R. Waters

Arantor

Well, if you don't have FTP access, there's not really a fat lot you can do. You can try looking in the Sources folder and likely candidates are QueryString.php, Subs.php, Load.php for the function you need to fix.

Sir Osis of Liver

Searched /public_html in file manager, nothing for 'optimus_buffer', only one .css file for 'optimus'.  Server errorlog is 2.3 mb, almost all of which was logged Dec 15/16.  Will see if I can convince owner to do clean install.  Don't know what's wrong with ftp, login successful, but can't retrieve directory.  Methinks it's time for a new host. :P
Ashes and diamonds, foe and friend,
 we were all equal in the end.

                                     - R. Waters

Arantor

Well, the code does exist, it is clearly being called according to the error message. If it were trying to call a function that does not exist, the error would be different. I cannot tell you why the file manager can't find it.

Kindred

looks at the mod...

      add_integration_function('integrate_buffer', 'Optimus::buffer', false);

Слaва
Украинi

Please do not PM, IM or Email me with support questions.  You will get better and faster responses in the support boards.  Thank you.

"Loki is not evil, although he is certainly not a force for good. Loki is... complicated."

Arantor

That's a current version but I suspect the older version as mentioned might not...

Kindred

Ah. yes. you are correct.

Looks at older package on test server

Subs-Optimus.php
function optimus_buffer(&$buffer)


In the install.php for the mod package

   'integrate_pre_include' => '$sourcedir/Subs-Optimus.php',
and
   'integrate_buffer' => 'optimus_buffer'
Слaва
Украинi

Please do not PM, IM or Email me with support questions.  You will get better and faster responses in the support boards.  Thank you.

"Loki is not evil, although he is certainly not a force for good. Loki is... complicated."

Arantor


Sir Osis of Liver

I'm beginning to suspect I'm in the wrong place.  The cpanel and ftp login credentials I'm using may be showing me old server, with different creds for new server.  Stranger things have happened.  But the forum is running, and Optimus mod is not listed in PM.
Ashes and diamonds, foe and friend,
 we were all equal in the end.

                                     - R. Waters

drewactual

is that forum running OPCache or akin that may require an invalidation of altered files?

Sir Osis of Liver

Don't think so.  It's on third server since end of Nov, I'm not even sure at this point if I'm accessing the current one.  Waiting for owner to get back with confirmed login creds.  Once I have ftp access again I can check the code directly, what I'm seeing in file manager can't be correct. 
Ashes and diamonds, foe and friend,
 we were all equal in the end.

                                     - R. Waters

Arantor

Just because Optimus is not in the package manager does not mean it is not installed. The error message clearly shows that it is.

Sir Osis of Liver

I know, but the cpanel code search doesn't find it, and that's all I have to work with until I can get back in via ftp.
Ashes and diamonds, foe and friend,
 we were all equal in the end.

                                     - R. Waters

Bob Perry of Web Presence Consulting

Quote from: Sir Osis of Liver on December 18, 2018, 03:38:51 PM
I know, but the cpanel code search doesn't find it, and that's all I have to work with until I can get back in via ftp.


Correct me if wrong, you have cpanel access but not ftp?
Best Regards,
Bob Perry



"The world is moving so fast these days that the man who says it can't be done is generally interrupted by someone doing it." Elbert Hubbard

Arantor

If you have cPanel,, why not make a new FTP account?

Advertisement: