cvs: pear /Log Log.php /Log/Log observer.php

From: Date: Tue, 24 Jun 2003 03:09:26 +0000
Subject: cvs: pear /Log Log.php /Log/Log observer.php
Groups: php.pear.cvs 
Request: Send a blank email to pear-cvs+get-11147@lists.php.net to get a copy of this message
jon Mon Jun 23 23:09:26 2003 EDT Modified files: /pear/Log Log.php /pear/Log/Log observer.php Log: The Log_observer class was setting it's unique identification number. This prevented observers from being attached to the array of listeners. Noticed by: Paul Wolstenholme Index: pear/Log/Log.php diff -u pear/Log/Log.php:1.30 pear/Log/Log.php:1.31 --- pear/Log/Log.php:1.30 Tue Jun 17 02:59:59 2003 +++ pear/Log/Log.php Mon Jun 23 23:09:26 2003 @@ -1,5 +1,5 @@ <?php -// $Id: Log.php,v 1.30 2003/06/17 06:59:59 jon Exp $ +// $Id: Log.php,v 1.31 2003/06/24 03:09:26 jon Exp $ // $Horde: horde/lib/Log.php,v 1.15 2000/06/29 23:39:45 jon Exp $ define('PEAR_LOG_EMERG', 0); /** System is unusable */ @@ -26,7 +26,7 @@ * * @author Chuck Hagenbuch <chuck@horde.org> * @author Jon Parise <jon@php.net> - * @version $Revision: 1.30 $ + * @version $Revision: 1.31 $ * @since Horde 1.3 * @package Log */ @@ -39,6 +39,14 @@ * @access private */ var $_opened = false; + + /** + * Instance-specific unique identification number. + * + * @var integer + * @access private + */ + var $_id = 0; /** * The label that uniquely identifies this set of log messages. Index: pear/Log/Log/observer.php diff -u pear/Log/Log/observer.php:1.5 pear/Log/Log/observer.php:1.6 --- pear/Log/Log/observer.php:1.5 Tue Apr 8 12:17:16 2003 +++ pear/Log/Log/observer.php Mon Jun 23 23:09:26 2003 @@ -1,5 +1,5 @@ <?php -// $Id: observer.php,v 1.5 2003/04/08 16:17:16 jon Exp $ +// $Id: observer.php,v 1.6 2003/06/24 03:09:26 jon Exp $ // $Horde: horde/lib/Log/observer.php,v 1.5 2000/06/28 21:36:13 jon Exp $ /** @@ -7,13 +7,21 @@ * pattern for watching log activity and taking actions on exceptional events. * * @author Chuck Hagenbuch <chuck@horde.org> - * @version $Revision: 1.5 $ + * @version $Revision: 1.6 $ * @since Horde 1.3 * @package Log */ class Log_observer { /** + * Instance-specific unique identification number. + * + * @var integer + * @access private + */ + var $_id = 0; + + /** * The minimum priority level of message that we want to hear about. * PEAR_LOG_EMERG is the highest priority, so we will only hear messages * with an integer priority value less than or equal to ours. It defaults @@ -24,7 +32,6 @@ */ var $_priority = PEAR_LOG_INFO; - /** * Creates a new basic Log_observer instance. * @@ -35,6 +42,7 @@ */ function Log_observer($priority = PEAR_LOG_INFO) { + $this->_id = md5(microtime()); $this->_priority = $priority; }

« previous php.pear.cvs (#11147) next »