Re: Refactoring in lock.c

From: Alvaro Herrera <alvherre(at)surnet(dot)cl>
To: Neil Conway <neilc(at)samurai(dot)com>
Cc: Patches <pgsql-patches(at)postgresql(dot)org>
Subject: Re: Refactoring in lock.c
Date: 2005-05-18 13:40:12
Message-ID: 20050518134012.GA7595@surnet.cl
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-patches

On Wed, May 18, 2005 at 12:33:51PM +1000, Neil Conway wrote:
> Alvaro Herrera wrote:
> >Additionally, I found that no callers of LockReleaseAll and LockRelease
> >had any use for their return values, so I made them return void.
>
> Is there a reason we can't just elog(ERROR) rather than returning?

I thought about that too. I'm not sure why the original code would
continue chugging along if the lock table is not consistent. Maybe it
was because back in the Berkeley days this code would step on bugs with
some regularity. I wonder if we could get away with changing it now.

Anyway, I didn't want to propose such a thing because a change in
functionality is not what I want to do in a refactor patch -- if the
idea is shot down, the whole thing is shot down and the patch is not
applied.

--
Alvaro Herrera (<alvherre[a]surnet.cl>)
Tulio: oh, para qué servirá este boton, Juan Carlos?
Policarpo: No, aléjense, no toquen la consola!
Juan Carlos: Lo apretaré una y otra vez.

In response to

Browse pgsql-patches by date

  From Date Subject
Next Message Sergey Ten 2005-05-18 20:27:55 Re: patches for items from TODO list
Previous Message Hannu Krosing 2005-05-18 10:07:27 Re: [HACKERS] read-only database