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

pgsql/src/backend/tcop (postgres.c)

From: Tom Lane <tgl>
To: pgsql-committers(at)postgresql(dot)org
Subject: pgsql/src/backend/tcop (postgres.c)
Date: 2000-04-30 21:29:24
Message-ID: 200004302129.RAA08961@hub.org (view raw or flat)
Thread:
Lists: pgsql-committers
  Date: Sunday, April 30, 2000 @ 17:29:23
Author: tgl

Update of /usr/local/cvsroot/pgsql/src/backend/tcop
     from hub.org:/home/tmp/cvs-serv8947

Modified Files:
	postgres.c 

-----------------------------  Log Message  -----------------------------

Reset CurrentMemoryContext to TopMemoryContext at the beginning of error
cleanup, ie, as soon as we have caught the longjmp.  This ensures that
current context will be a valid context throughout error cleanup.  Before
it was possible that current context was pointing at a context that would
get deleted during cleanup, leaving any subsequent pallocs in deep
trouble.  I was able to provoke an Assert failure when compiled with
asserts + -DCLOBBER_FREED_MEMORY, if I did something that would cause
an error to be reported by the backend large-object code, because indeed
that code operates in a context that gets deleted partway through xact
abort --- and CurrentMemoryContext was still pointing at it!  Boo hiss.

pgsql-committers by date

Next:From: Tatsuo IshiiDate: 2000-05-02 08:13:08
Subject: pgsql/src/backend/utils/init (miscinit.c)
Previous:From: Tom LaneDate: 2000-04-30 21:23:32
Subject: pgsql/src/backend/storage/lmgr (lock.c)

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