Skip site navigation (1) Skip section navigation (2)

Re: pgsql: Fix portalmem.c to avoid keeping a dangling pointer to a cached

From: tgl(at)postgresql(dot)org (Tom Lane)
To: pgsql-committers(at)postgresql(dot)org
Subject: pgsql: Fix portalmem.c to avoid keeping a dangling pointer to a cached
Date: 2010-01-18 02:30:25
Message-ID: 20100118023025.EE5067541B9@cvs.postgresql.org (view raw)
Log Message:
-----------
Fix portalmem.c to avoid keeping a dangling pointer to a cached plan list
after it's released its reference count for the cached plan.  There are
code paths that might try to examine the plan list before noticing that
the portal is already in aborted state.  Report and diagnosis by Tatsuo
Ishii, though this isn't exactly his proposed patch.

Modified Files:
--------------
    pgsql/src/backend/utils/mmgr:
        portalmem.c (r1.115 -> r1.116)
        (http://anoncvs.postgresql.org/cvsweb.cgi/pgsql/src/backend/utils/mmgr/portalmem.c?r1=1.115&r2=1.116)

From: Tatsuo Ishii <ishii(at)postgresql(dot)org>
To: tgl(at)postgresql(dot)org
Cc: pgsql-committers(at)postgresql(dot)org, pgsql-hackers(at)postgresql(dot)org
Subject: Re: pgsql: Fix portalmem.c to avoid keeping a dangling pointer to a cached
Date: 2010-01-18 03:44:18
Message-ID: 20100118.124418.62367192.t-ishii@sraoss.co.jp (view raw)
> Log Message:
> -----------
> Fix portalmem.c to avoid keeping a dangling pointer to a cached plan list
> after it's released its reference count for the cached plan.  There are
> code paths that might try to examine the plan list before noticing that
> the portal is already in aborted state.  Report and diagnosis by Tatsuo
> Ishii, though this isn't exactly his proposed patch.
> 
> Modified Files:
> --------------
>     pgsql/src/backend/utils/mmgr:
>         portalmem.c (r1.115 -> r1.116)
>         (http://anoncvs.postgresql.org/cvsweb.cgi/pgsql/src/backend/utils/mmgr/portalmem.c?r1=1.115&r2=1.116)

Thanks. I confirmed the problem goes away. BTW, are we going to back
patch to 8.2 or before?
--
Tatsuo Ishii
SRA OSS, Inc. Japan

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Tatsuo Ishii <ishii(at)postgresql(dot)org>
Cc: pgsql-committers(at)postgresql(dot)org, pgsql-hackers(at)postgresql(dot)org
Subject: Re: pgsql: Fix portalmem.c to avoid keeping a dangling pointer to a cached
Date: 2010-01-18 04:11:40
Message-ID: 25352.1263787900@sss.pgh.pa.us (view raw)
Tatsuo Ishii <ishii(at)postgresql(dot)org> writes:
> Thanks. I confirmed the problem goes away. BTW, are we going to back
> patch to 8.2 or before?

That code isn't there before 8.3.

			regards, tom lane


Privacy Policy | About PostgreSQL
Copyright © 1996-2013 The PostgreSQL Global Development Group