Re: unused variable ShmemBootstrap

Lists: pgsql-patches
From: Alvaro Herrera <alvherre(at)dcc(dot)uchile(dot)cl>
To: Patches <pgsql-patches(at)postgresql(dot)org>
Subject: unused variable ShmemBootstrap
Date: 2005-03-30 02:33:45
Message-ID: 20050330023345.GA7632@dcc.uchile.cl
Views: Raw Message | Whole Thread | Download mbox | Resend email
Lists: pgsql-patches

Patchers,

src/backend/storage/shmem.c contains an unused variable; it's only
assigned to, and used in a couple Assert(). It's been this way since
shmem.c 1.53, which was current on july 2000.

This patch removes it, along with an obsolete comment (which refers to a
file and function that hasn't existed at all in the whole CVS history.)

--
Alvaro Herrera (<alvherre[(at)]dcc(dot)uchile(dot)cl>)
"There is evil in the world. There are dark, awful things. Occasionally, we get
a glimpse of them. But there are dark corners; horrors almost impossible to
imagine... even in our worst nightmares." (Van Helsing, Dracula A.D. 1972)

Attachment Content-Type Size
shmem-boostrap.patch text/plain 2.9 KB

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Alvaro Herrera <alvherre(at)dcc(dot)uchile(dot)cl>
Cc: Patches <pgsql-patches(at)postgresql(dot)org>
Subject: Re: unused variable ShmemBootstrap
Date: 2005-03-30 04:48:57
Message-ID: 18569.1112158137@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Lists: pgsql-patches

Alvaro Herrera <alvherre(at)dcc(dot)uchile(dot)cl> writes:
> This patch removes it, along with an obsolete comment (which refers to a
> file and function that hasn't existed at all in the whole CVS history.)

I agree that the code is useless, but exactly which comment are you
complaining of?

regards, tom lane


From: Alvaro Herrera <alvherre(at)dcc(dot)uchile(dot)cl>
To: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
Cc: Patches <pgsql-patches(at)postgresql(dot)org>
Subject: Re: unused variable ShmemBootstrap
Date: 2005-03-30 14:56:10
Message-ID: 20050330145610.GA32434@dcc.uchile.cl
Views: Raw Message | Whole Thread | Download mbox | Resend email
Lists: pgsql-patches

On Tue, Mar 29, 2005 at 11:48:57PM -0500, Tom Lane wrote:
> Alvaro Herrera <alvherre(at)dcc(dot)uchile(dot)cl> writes:
> > This patch removes it, along with an obsolete comment (which refers to a
> > file and function that hasn't existed at all in the whole CVS history.)
>
> I agree that the code is useless, but exactly which comment are you
> complaining of?

Oops, somehow I left that parth out of the patch.

*** shmem.c 31 Dec 2004 22:00:56 -0000 1.82
--- shmem.c 30 Mar 2005 14:56:46 -0000
***************
*** 53,61 ****
* cannot be redistributed to other tables. We could build a simple
* hash bucket garbage collector if need be. Right now, it seems
* unnecessary.
- *
- * See InitSem() in sem.c for an example of how to use the
- * shmem index.
*/

#include "postgres.h"
--- 53,58 ----

--
Alvaro Herrera (<alvherre[(at)]dcc(dot)uchile(dot)cl>)
"¿Cómo puedes confiar en algo que pagas y que no ves,
y no confiar en algo que te dan y te lo muestran?" (Germán Poo)


From: Neil Conway <neilc(at)samurai(dot)com>
To: Alvaro Herrera <alvherre(at)dcc(dot)uchile(dot)cl>
Cc: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>, Patches <pgsql-patches(at)postgresql(dot)org>
Subject: Re: unused variable ShmemBootstrap
Date: 2005-04-04 04:35:02
Message-ID: 4250C3F6.2060409@samurai.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Lists: pgsql-patches

Alvaro Herrera wrote:
> Oops, somehow I left that parth out of the patch.

Thanks, both patches applied.

-Neil