PHP 4.4.0 ReleasedThe PHP Development Team would like to announce the immediate release of PHP 4.4.0. This is a maintenance release that addresses a serious memory corruption problem within PHP concerning references. If references were used in a wrong way, PHP would often create memory corruptions which would not always surface and be visible. The increased middle digit was required because the fix that corrected the problem with references changed PHP’s internal API. PHP 4.4.0 does not have any new features, and is solely a bugfix release.
PHP 4.4.0がリリース。バグ修正だそうです。
PHP: PHP 4 ChangeLogFixed bug #32685, Fixed bug #29423 (Segfault when using assignment by reference within function).
ChangeLogではこの「関数内で参照代入するとsegfault」ってやつが一番でかそうです。
・・・ぐらいに思ってたのにMojavi2動かすと、
PHP Notice: Only variable references should be returned by reference(略
PHP Notice: Only variable references should be returned by reference(略
PHP Notice: Only variable references should be returned by reference(略
PHP Notice: Only variable references should be returned by reference(略
mojavi-all-classes.phpでNotice出まくり。原因はまさにコレ。参照返ししてるのに値で代入したり、値返ししてるのに参照代入すると注意されるようになったためです。たしかに注意してくれるとありがたいですが、Mojavi2のエラーハンドリングの仕組みが動く前(Controller::dispatchの中でset_error_handler)なので止めようが無し。
とにかく困ってる人はこうすればとりあえずは凌げるっぽいです。
mojavi-all-classes.php
// this is an uncommented, auto-generated file
// for full source, please view the Mojavi lib directory
//error_reporting(E_ALL);
error_reporting(E_ALL & ~E_NOTICE);
あとでがんばってNOTICE元を全部修正したパッチを作りたいです。
2006/03/07追記: 修正版はこちら