Re: Cache invalidation bug in RelationGetIndexAttrBitmap() - Mailing list pgsql-hackers

From Tom Lane
Subject Re: Cache invalidation bug in RelationGetIndexAttrBitmap()
Date
Msg-id 25420.1400084127@sss.pgh.pa.us
Whole thread Raw
In response to Cache invalidation bug in RelationGetIndexAttrBitmap()  (Andres Freund <andres@2ndquadrant.com>)
Responses Re: Cache invalidation bug in RelationGetIndexAttrBitmap()
List pgsql-hackers
Andres Freund <andres@2ndquadrant.com> writes:
> On 2014-05-14 15:17:39 +0200, Andres Freund wrote:
>> My gut feeling says it's in RelationGetIndexList().

> Nearly right. It's in RelationGetIndexAttrBitmap(). Fix attached.

TBH, I don't believe this patch at all.  Where exactly is rd_replidindex
reset?  If it's supposed to have similar lifespan to, say, rd_oidindex,
why isn't it being handled like rd_oidindex?  And why does the header
comment for RelationGetIndexList make no mention of this new side-effect?
Somebody did a seriously poor job of adding this functionality to
relcache.
        regards, tom lane



pgsql-hackers by date:

Previous
From: Andres Freund
Date:
Subject: Re: btree_gist valgrind warnings about uninitialized memory
Next
From: Tom Lane
Date:
Subject: Re: btree_gist valgrind warnings about uninitialized memory