On Sat, Nov 14, 2009 at 6:36 PM, Tom Lane <t...@sss.pgh.pa.us> wrote:
> There's an example in parse_oper.c of a specialized cache that's about
> as complicated as this would be.

I was just taking a look at find_oper_cache_entry() and noticed
something odd.  When we discover that OprCacheHash == NULL, we make
sure that CacheMemoryContext is initialized before calling
hash_create().  But since we don't pass HASH_CONTEXT to hash_create(),
ISTM it's going to use TopMemoryContext anyhow.  utils/mmgr/README
indicates that the two contexts are basically equivalent anyway so I
don't think there's any visible breakage as a result of this, but it
sort of looks like an oversight.

...Robert

-- 
Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-hackers

Reply via email to