Recent Topics

1 Aug 24, 2005 23:29    

b2evolution dev team,

FYI I have gotten thousands of these errors in my logs.

PHP Notice: Only variable references should be returned by reference in [snip...] \\evocore\\_plugins.class.php on line 368

It appears that this error is generated when the function returns false instead of a variable.

The version of that file is * @version $Id: _plugins.class.php,v 1.9 2005/03/02 18:44:27 fplanque Exp $

I'm using a CVS version downloaded on 2005.08.15

I fixed the error by changing the function declaration from:
function & get_next()

to:
function get_next()

Nothing visibly broke when I did this but I haven't really tested it much. So caveat emptor for those who might do this at well - it could be quite unwise =).

Can anyone shed some light on this?

I'm running Apache2 on Win2k3 with PHP 4.4.0

Keep up the good work!
- Matt

2 Jan 02, 2007 13:58

Hi matthius,

Even though I'm not part of the dev team, I thought I'd give you my input. :-)

I got a similar problem in _dataobjectlist.class.php on line 111 in function & get_next().

$r = false;
return $r; -- Notice: Only variable references should be returned by reference--

Instead of modifying the function declaration I simply added

$r = false;
$temp = & $r;
return $temp;

Now it doesn't complain anymore.

I hope this helps,

Regards
-Jor-el

3 Jan 28, 2007 10:21

Hi!

Yes the correct fix is
$r = false;
return $r;

Would you guys mind fixing these in CVS when you find them?
(Please contact me for CVS access)

Thanks.

4 Feb 17, 2007 22:05

fplanque, read the post above yours again. It seems that "$r = false; return $r;" has been used already, but caused the notice.

5 Jul 22, 2007 01:26

Unfortunately problems persist in the CSV 2,0 I recently downloaded. If somebody can tell me how I can upload files (TurtoiseCVS installed) I will fix the files.

6 Jul 22, 2007 01:37

Afwas you need to be granted permission, blueyed and francois can grant you that permission. From memory with TortoiseCVS you just make the changes to the file as you normally, right click it, and then "commit", but I haven't used it since b2evo 1.8 came out, so my memory is lacking.

7 Jul 22, 2007 19:22

JFI: I cannot grant any permissions.

8 Nov 06, 2007 18:45

I found this problem in the latest CVS as of today.

The file is inc/_core/_template.funcs.php line 428

I solved it changing the aforementioned line as this:

$temp = $MainList ->get_item();
return $temp

I'm runing PHP version 4.4.4

This program makes use of the Zend Scripting Language Engine:
Zend Engine v1.3.0, Copyright (c) 1998-2004 Zend Technologies with the ionCube PHP Loader v3.1.29, Copyright (c) 2002-2007, by ionCube Ltd., and with Zend Extension Manager v1.0.10, Copyright (c) 2003-2006, by Zend Technologies with Zend Optimizer v3.0.1, Copyright (c) 1998-2006, by Zend Technologies

9 Nov 08, 2007 18:59

Austriaco, thanks for the fix, I've just committed it (slightly changed).

10 Nov 08, 2007 19:09

Is this really true? Did Austriaco just solve a three year old major annoying problem with just one line of code?

WOW

11 Nov 08, 2007 19:59

I'd like to take credit, but I merely took the solution from another thread and applied to this particular case.

12 Nov 09, 2007 19:29

This is a quite common problem, and there might be other places which need the same fix still.

14 Nov 09, 2007 23:04

It's another problem over there actually. I remember having (hackishly) fixed the first problem, but have no clue about the others (they are different). You may want to figure out the problem yourself - e.g. by installing xdebug, which provided backtraces for errors, warnings and notices.


Form is loading...