[Phpmyadmin-devel] a PHP 5.1.2 bug?

Garvin Hicking phpmyadmin at supergarv.de
Fri Jan 13 07:11:14 CET 2006


Hi Sebastian!

> printLocalDate(time() + 60*60*24 * 12); // current time plus 12 days
> and
> myFunc($var = 'value');
> is not much different, or?

Actually, this is much different. The first call doesn't need to to any variable
assignment. The second call does, and needs to store it somewhere in memory.

Exactly this "store it in memory" has in the past time led to memory corruption,
and was the reason why the PHP notice "Fatal error/Warning: Only variables can
be passed by reference..." [1] was introduced, resulting in one really big BC
break.

I think your method is a follow-up to that same problem, but it should also not
have become changed without any notice in the ChangeLog. But it seems not many
people use that mechanism, so it has/may not yet been reported. Which is all the
more reason to post this report on bugs.php.net.

[1] http://cow.neondragon.net/index.php/375-Annoying-Things-About-Php
    http://phplens.com/phpeverywhere/?q=node/view/214

Regards,
Garvin

-- 
++ Garvin Hicking | Web-Entwickler [PHP]    | www.garv.in | ICQ 21392242
++ Developer of   | www.phpMyAdmin.net      | www.s9y.org

++ Make me happy  | http://wishes.garv.in





More information about the Developers mailing list