Re: Re: Possible problem in PEAR Log

From: Date: Thu, 04 Jul 2002 11:48:17 +0000
Subject: Re: Re: Possible problem in PEAR Log
References: 1 2 3 4 5 6 7 8 9 10  Groups: php.pear.dev 
Request: Send a blank email to pear-dev+get-7465@lists.php.net to get a copy of this message
At 22:45 03/07/2002 -0400, Jon Parise wrote:
On Wed, Jul 03, 2002 at 05:34:14PM +0100, Michael Dransfield wrote: It was only marked as a possible problem, couldnt it be solved by using a seperate set of constants (PEAR_LOG_*) which could then be mapped to the LOG_ constants if needed for syslog features where the integer is needed. I think that this proposal is resonable, although it will break backwards compatibility and will require us to react according to the current operating platform at runtime.
I do not think it needs to break bc at all, I am attaching a diff, for Log/Log.php which seems to work here for either the PEAR_ or LOG_ constants. It will need an extra function which can convert a PEAR_ constant to a LOG_ constant in syslog. A simple function like priorityToString should do array (
        PEAR_LOG_ERROR => LOG_ERROR,
        etc...etc....
)

« previous php.pear.dev (#7465) next »