projects
/
postgresql.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
673b527
)
Initialize cached OID to Invalid in new hash entries
author
Alvaro Herrera
Tue, 27 Aug 2013 18:53:17 +0000
(14:53 -0400)
committer
Alvaro Herrera
Tue, 27 Aug 2013 18:53:17 +0000
(14:53 -0400)
Andres Freund; bug detected by valgrind
src/backend/utils/cache/relfilenodemap.c
patch
|
blob
|
blame
|
history
diff --git
a/src/backend/utils/cache/relfilenodemap.c
b/src/backend/utils/cache/relfilenodemap.c
index 2a8f83775d26c6daa3f2a2ac2891ee2c4b81dafc..f3f9a098996a9f1c3eadca8248a0591fcefcd026 100644
(file)
--- a/
src/backend/utils/cache/relfilenodemap.c
+++ b/
src/backend/utils/cache/relfilenodemap.c
@@
-180,6
+180,9
@@
RelidByRelfilenode(Oid reltablespace, Oid relfilenode)
if (found)
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 */
/* check shared tables */