pg.ddx.io  pgsql-php@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Brent R. Matzelle <bmatzelle@yahoo.com>
To: Mike Rogers <temp6453@hotmail.com>
To: pgsql-php@postgresql.org
Subject: Re: PostgreSQL / PHP Overrun Error
Date: Wed, 26 Sep 2001 13:05:10 -0700 (PDT)
Message-ID: <20010926200510.6710.qmail@web13008.mail.yahoo.com> (raw)
In-Reply-To: <OE64wAeRaNgEpTX5V3G00002a0a@hotmail.com>

--- Mike Rogers <temp6453@hotmail.com> wrote:
> I am currently running PHP-4.0.6 (with the memory leak patch
> as posted to
> correct a problem in this release [it is on the download
> page]).
> The script that causes them mostly "includes" other scripts to
> do it's job.
> The home page uses some of the scripts that it uses and I've
> seen the errors
> there too.  There errors seem infrequent, and just occur
> randomly... Maybe
> every 2-10 minutes on a reasonably high-volume server.  The
> commands that
> seem to be getting executed by the script [it's not my
> script]:
>     pg_exec
>     pg_errormessage
>     pg_fetch_array
>     pg_errormessage
>     pg_freeresult
>     pg_fieldname
>     pg_fieldtype
>     pg_fieldsize
>     pg_cmdtuples
>     pg_numrows
>     pg_numfields

All of those functions are okay to use except that I would
commment out the calls to pg_freeresult().  I have seen various
older bug reports that have noted that this function can be 
troublesome.  Plus, PHP frees this memory automatically whether
you call this function or not.  I rarely use this function,
unless I am making queries that return enormous amounts of data,
and even then I really do not require it.

Last note, the PHP debug information that you gathered seemed to
be cleaning up the pg_notice memory if I was not mistaken.  I
would not be surprised if this function was called by
pg_freeresult.  

Brent

__________________________________________________
Do You Yahoo!?
Get email alerts & NEW webcam video instant messaging with Yahoo! Messenger. http://im.yahoo.com



view thread (24+ messages)  latest in thread

Message-ID: <20010926200510.6710.qmail@web13008.mail.yahoo.com>
Permalink:  ../20010926200510.6710.qmail@web13008.mail.yahoo.com/
Also on:    postgresql.org/message-id/20010926200510.6710.qmail@web13008.mail.yahoo.com

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients from your mail client; the link fills in
  the headers below: reply via email
  Some clients, webmail especially, drop In-Reply-To and References from
  a link, and the reply then starts a new thread: use the mbox below.

  To: pgsql-php@postgresql.org
  Cc: bmatzelle@yahoo.com, temp6453@hotmail.com
  Subject: Re: PostgreSQL / PHP Overrun Error
  In-Reply-To: <20010926200510.6710.qmail@web13008.mail.yahoo.com>
  References: <OE64wAeRaNgEpTX5V3G00002a0a@hotmail.com> <20010926200510.6710.qmail@web13008.mail.yahoo.com>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox