Re: PostgreSQL / PHP Overrun Error

From: Date: Thu, 27 Sep 2001 00:21:18 +0000
Subject: Re: PostgreSQL / PHP Overrun Error
References: 1  Groups: php.dev 
Request: Send a blank email to php-dev+get-66694@lists.php.net to get a copy of this message
4.0.7 will include this fix. All I can say is that it's supposed to come out 'soon'... About that leak - can you test the latest CVS again? :) At 01:58 27-09-01, Mike Rogers wrote:
Hi Zeev;
    Seems to have fixed the problem.  What is this expected to be included
in a final version 4.0.7 I assume... I try to avoid alpha/beta but I suppose I have little choice at this time. Now I just see enormous amounts of:
    string.c(1341) :  Freeing 0x086AB454 (6 bytes), script=/path/to/scripts
    I assume that's normal in debug mode for the Zend cleanup engines...  So
I suppose all is well. Thank you so much. If you have a guestimate on the next release including all of this, that would be amaizing. Thanks for all of your help; -- Mike ----- Original Message ----- From: "Zeev Suraski" <zeev@zend.com> To: "Mike Rogers" <temp6453@hotmail.com> Cc: <php-db-help@lists.php.net>; <php-dev@lists.php.net> Sent: Wednesday, September 26, 2001 6:51 PM Subject: Re: [PHP-DEV] PostgreSQL / PHP Overrun Error Can you try the latest CVS? It should fix the problem. Zeev At 18:35 26-09-01, Mike Rogers wrote:
I have just upgraded to the new PostgreSQL 7.1.3 (from 7.0.3) and have
been
experiencing a pretty serious problem:
    On one particular page, in what seems to be completely random
instances,
I get buffer overruns and either 0-rows or a crashed apache child.
Turning
on PHP's --enable-debug, I receive the following [in httpd error log]: [Wed Sep 26 06:21:12 2001] Script: '/path/to/script.php' --------------------------------------- pgsql.c(167) : Block 0x086A6DF8 status:
Beginning:      Overrun (magic=0x00000000, expected=0x7312F8DC)
      End:      Unknown
--------------------------------------- Sometimes it will actually crash mid-way (probably overwrote some
valuable
code): --------------------------------------- pgsql.c(167) : Block 0x08684290 status:
Beginning:      Overrun (magic=0x0000111A, expected=0x7312F8DC)
[Wed Sep 26 09:22:46 2001] [notice] child pid 8710 exit signal
Segmentation
fault (11) This problem is of great concern to me and I have been working for days trying to debug it myself and find other reports, with little success.
The
line it claims to be failing on is PHP's ext/pgsql/pgsql.c on line 167
(by
what this claims) which is the following function [the efree(PGG(last_notice)) line]. static void _notice_handler(void *arg, const char *message) {
        PGLS_FETCH();
        if (! PGG(ignore_notices)) {
                php_log_err((char *) message);
                if (PGG(last_notice) != NULL) {
                        efree(PGG(last_notice));
                }
                PGG(last_notice) = estrdup(message);
        }
} Can anyone provide further input as to why this is causing problems? The PHP code works sometimes and not others, and it seems to be only that one script, so I do not believe it to be a hardware issue. Any thoughts? I can provide any further system information if needed. I have tried recompiling pgsql, php and apache with different optimizations [including none at all and debug mode on as i have now] with little
change
in the result. Thanks in advance; -- Mike cc: pgp-db-help; pgp-dev -- PHP Development Mailing List <http://www.php.net/> To unsubscribe, e-mail: php-dev-unsubscribe@lists.php.net For additional commands, e-mail: php-dev-help@lists.php.net To contact the list administrators, e-mail: php-list-admin@lists.php.net
-- PHP Development Mailing List <http://www.php.net/> To unsubscribe, e-mail: php-dev-unsubscribe@lists.php.net For additional commands, e-mail: php-dev-help@lists.php.net To contact the list administrators, e-mail: php-list-admin@lists.php.net -- PHP Development Mailing List <http://www.php.net/> To unsubscribe, e-mail: php-dev-unsubscribe@lists.php.net For additional commands, e-mail: php-dev-help@lists.php.net To contact the list administrators, e-mail: php-list-admin@lists.php.net


« previous php.dev (#66694) next »