PHP pgsql Extension does not load with PostgreSQL < 7.4 because of PQfreemem
| Bug #41845 | PHP pgsql Extension does not load with PostgreSQL < 7.4 because of PQfreemem | ||||
|---|---|---|---|---|---|
| Submitted: | 2007-06-28 18:30 UTC | Modified: | 2007-07-02 15:37 UTC | ||
| From: | bilal at revolutionhosting dot net | Assigned: | iliaa (profile) | ||
| Status: | Closed | Package: | PostgreSQL related | ||
| PHP Version: | 5.2.3 | OS: | Fedora Core 1, RHEL 3 | ||
| Private report: | No | CVE-ID: | None | ||
[2007-06-28 18:30 UTC] bilal at revolutionhosting dot net
Description: ------------ Same as closed Bug #40418 for PHP 5.2.1 (PQfreemem does not exist prior to Postgresql 7.4). <http://bugs.php.net/bug.php?id=40418> This bug exists in PHP 5.2.3. It seems to have either been never completely fixed in ext/pgsql/pgsql.c, or perhaps reverted in PHP 5.2.3. The ext/pgsql/config.m4 does now check whether PQfreemem is available, but ext/pgsql/pgsql.c continues to use PQfreemem regardless, causing PHP to be unable to load the pgsql extension on systems with PostgreSQL version less than 7.4 (Fedora Core 1, RHEL 3). Patch from Bug #40418 should work. Reproduce code: --------------- Build PHP 5.2.3 with ./configure --with-pgsql=shared Install and attempt to run PHP (ex. "php -m"). Expected result: ---------------- No errors shown, extensions (including "pgsql") listed. Actual result: -------------- PHP emits a warning that it is unable to load pgsql.so: "undefined symbol: PQfreemem in Unknown on line 0"
Patches
Pull Requests
History
AllCommentsChangesGit/SVN commits
[2007-07-02 15:37 UTC] iliaa@php.net