[horde] New pear DB problem

Sébastien Guay sebasguay at gmail.com
Thu Jul 21 10:37:42 PDT 2005


Hi,

I have Horde 2.2.5 with IMP 3.2.3 and it had worked great for more
than one year.

I recently upgraded php to 4.4.0 from php-4.3.11 and pear::DB as well
(to 1.7.6 from 1.7.5).

Since then, Horde is no longer functioning.  If I downgrade back to
4.3.11, all is OK.

The problem lies with the pear DB extension.  You can check at
http://webmail.belzebuth.ca/horde/test.php

The latest DB extension is installed
root at Ezekiel:~# pear upgrade DB
Package 'DB-1.7.6' already installed, skipping

How is it that Horde make a version check with a value of 2 when then
latest is 1.7.6?
[quote from test.php]
/* Check the version of the pear database API. */
if ($peardb) {
    $peardbversion = '0';
    $peardbversion = @DB::apiVersion();
    if ($peardbversion < 2) {
        $peardb = false;
    }
}
[/quote]

If I put an 'echo $peardbversion;' before the second if, I get 1.7.6
as it should be.  Why on earth Horde is checking <2 ?

Even if I manually change in /usr/lib/php/DB.php

    function apiVersion()
    {
        return '1.7.6';
    }

to 

    function apiVersion()
    {
        return 2;
    }

it doesn't work.

As I said, the only way to get Horde working again is by downgrading
php to 4.3.11 (which break the mysql support in PHP).

Any ideas / workarounds?

Thanks

Sébas


More information about the horde mailing list