php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #1621 pg_fetch_row & pg_fieldname ok | pg_fetch_array & pg_fetch_object -> PHP dies
Submitted: 1999-06-28 23:36 UTC Modified: 1999-06-29 03:28 UTC
From: bandit at freeside dot elte dot hu Assigned:
Status: Closed Package: PostgreSQL related
PHP Version: 3.0.11 OS: Linux 2.0.37
Private report: No CVE-ID: None
 [1999-06-28 23:36 UTC] bandit at freeside dot elte dot hu
Intel/Linux 2.0.37 libc 5.4.33
gcc version 2.7.2p 970821 (egcs-970821)
PostgresSQL 6.5
PHP 3.0.11 compiled as Apache module
Apache 1.3.6

/usr/src/php-3.0.11# ./configure --with-apache=../apache_1.3.6 --enable-track-vars --with-pgsql --with-zlib

Apache 1.3.4 compiled with PHP 3.0.6, same environment (same pgsql and database, same php3.ini, same script) works.

$result1=pg_exec($conn,"select topic,count(*) as count from \"msgboard messages\" where expired<>'t' group by topic;");
$rows=pg_numrows($result1);
for($row=0;$row<$rows;$row++) {
        $obj=pg_fetch_array($result1,$row); // here it happens
        //$darab[$obj[topic]]=$obj[count];
}

I apologize for the lack of a backtrace, but my efforts to generate a core file by following the instructions remained fruitless.

Regards,
Andras

Patches

Pull Requests

History

AllCommentsChangesGit/SVN commitsRelated reports
 [1999-06-29 03:28 UTC] sas at cvs dot php dot net
fixed in CVS. Apply the following patch:

http://cvs.php.net/cvsweb.cgi/functions/pgsql.c.diff?r1=1.85&r2=1.86
 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Sat Dec 21 13:01:31 2024 UTC