Commit e246cfc9 authored by Alvaro Herrera's avatar Alvaro Herrera

Initialize cached OID to Invalid in new hash entries

Andres Freund; bug detected by valgrind
parent 673b5275
...@@ -180,6 +180,9 @@ RelidByRelfilenode(Oid reltablespace, Oid relfilenode) ...@@ -180,6 +180,9 @@ RelidByRelfilenode(Oid reltablespace, Oid relfilenode)
if (found) if (found)
return entry->relid; return entry->relid;
/* initialize empty/negative cache entry before doing the actual lookup */
entry->relid = InvalidOid;
/* ok, no previous cache entry, do it the hard way */ /* ok, no previous cache entry, do it the hard way */
/* check shared tables */ /* check shared tables */
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment