Re: missing LockBuffer(buffer, BUFFER_LOCK_SHARE) in trigger.c GetTupleForTrigger? - Mailing list pgsql-hackers

From Andres Freund
Subject Re: missing LockBuffer(buffer, BUFFER_LOCK_SHARE) in trigger.c GetTupleForTrigger?
Date
Msg-id 20121130191231.GK3957@awork2.anarazel.de
Whole thread Raw
In response to Re: Re: missing LockBuffer(buffer, BUFFER_LOCK_SHARE) in trigger.c GetTupleForTrigger?  (Tom Lane <tgl@sss.pgh.pa.us>)
Responses Re: missing LockBuffer(buffer, BUFFER_LOCK_SHARE) in trigger.c GetTupleForTrigger?
Re: Re: missing LockBuffer(buffer, BUFFER_LOCK_SHARE) in trigger.c GetTupleForTrigger?
List pgsql-hackers
On 2012-11-30 14:08:05 -0500, Tom Lane wrote:
> BTW, I went looking for other places that might have a similar mistake.
> I found that contrib/pageinspect/btreefuncs.c pokes around in btree
> pages without any buffer lock, which seems pretty broken --- don't we
> want it to take share lock?

I seem to remember comments somewhere indicating that pageinspect (?)
doesn't take locks by intention to make debugging of locking problems
easier. Not sure whether thats really realistic, but ...

Andres

-- Andres Freund                       http://www.2ndQuadrant.com/PostgreSQL Development, 24x7 Support, Training &
Services



pgsql-hackers by date:

Previous
From: Tom Lane
Date:
Subject: Re: Re: missing LockBuffer(buffer, BUFFER_LOCK_SHARE) in trigger.c GetTupleForTrigger?
Next
From: Tom Lane
Date:
Subject: Re: missing LockBuffer(buffer, BUFFER_LOCK_SHARE) in trigger.c GetTupleForTrigger?