Re: [COMMITTERS] pgsql: We no longer need to palloc the VacuumStmt node; keeping it on

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Alvaro Herrera <alvherre(at)commandprompt(dot)com>
Cc: pgsql-hackers(at)postgresql(dot)org
Subject: Re: [COMMITTERS] pgsql: We no longer need to palloc the VacuumStmt node; keeping it on
Date: 2007-03-23 21:22:22
Message-ID: 25086.1174684942@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-committers pgsql-hackers

alvherre(at)postgresql(dot)org (Alvaro Herrera) writes:
> We no longer need to palloc the VacuumStmt node; keeping it on the stack is
> simpler.

If you're going to do that, you should at least set the nodeTag so that
the struct appears valid to onlookers. A memset wouldn't be out of
place either to make sure that any uninitialized fields behave sanely.

regards, tom lane

In response to

Responses

Browse pgsql-committers by date

  From Date Subject
Next Message Alvaro Herrera 2007-03-23 21:23:13 pgsql: Separate fetch of pg_autovacuum tuple into its own function.
Previous Message User Dpage 2007-03-23 21:19:07 stackbuilder - wizard: Download using a sensible chunk size - 4Kb seems

Browse pgsql-hackers by date

  From Date Subject
Next Message Tom Lane 2007-03-23 21:49:42 Re: EXISTS optimization
Previous Message Alvaro Herrera 2007-03-23 20:56:40 pgsql: We no longer need to palloc the VacuumStmt node; keeping it on