Custom Query (307 matches)

Filters
 
Or
 
  
 
Columns

Show under each result:


Results (52 - 54 of 307)

Ticket Resolution Summary Owner Reporter
#223 fixed E_DEPRECATED error at parsing - Custom error handler cant access previously declared classes moo patphobos
Description
<?php

error_reporting(E_ALL);
set_error_handler('error');

function error($errno, $errstr, $errfile, $errline, $errcontext)
{
    echo "PHP ERROR - error n°" . $errno . ' : ' . $errstr . "\n";
    if (!class_exists('test42'))
        echo " - hit a bug, test42";
    die();
}
class test42 { }

require_once 'page_with_an_error.php';

?>

page_with_an_error.php:

<?php
function test(&$val) { }
$val = 'this is a test';

// Deprecated :
test(&$val);

?>

the custom error handler is catching the E_DEPRECATED error, but when cached, the error handler cant use any of previously existing objects (like test42 in this example).

Another testcase, that made my php5.3 to segfault :

<?php

error_reporting(E_ALL);
set_error_handler('error');

function error($errno, $errstr, $errfile, $errline, $errcontext)
{
    if (!defined('DISPLAY_ERROR'))
        define('DISPLAY_ERROR', true);

    if (DISPLAY_ERROR)
        echo "PHP ERROR - error n°" . $errno . ' : ' . $errstr . "\n";
}

// 1st error E_DEPRECATED inside page_with_an_error.php
include 'page_with_an_error.php';

// 2nd error
asort();

?>

'page_with_an_error.php' is the same file with the deprecated call by reference error.

#127 wontfix E_STRICT errors not caught by custom error handler moo c960657
Description

I use a custom error handler to mute E_STRICT errors generated by PEAR but display E_STRICT errors caused by my own code.

Without Xcache this works fine. When using Xcache not all errors are caught by the custom error handler.

<?php
function myErrorHandler($no, $msg, $file, $line) {
    if ($no == E_STRICT && strpos($file, '/pear/')) {
        // PEAR isn't E_STRICT compatible, so just ignore E_STRICT errors there
        return;
    }
    // Report error as usual
    // ...
}
set_error_handler('myErrorHandler');
require_once 'PEAR.php';
?>

When Xcache is enabled, PHP prints two error messages:

Strict Standards: Assigning the return value of new by reference is deprecated in /var/www/test.peytz.dk/pear/PEAR.php on line 569 Strict Standards: Assigning the return value of new by reference is deprecated in /var/www/test.peytz.dk/pear/PEAR.php on line 572

This only happens the first time the script is run after the cache has been emptied.

#86 fixed Enhance in xcache admin moo safari
Description

Currently, there's no way to unset/delete a var entry (data) in admin interface. Could you consider to add this feature?

Note: See TracQuery for help on using queries.