aboutsummaryrefslogtreecommitdiff
path: root/src/backend/access/transam/xlogutils.c
diff options
context:
space:
mode:
authorTom Lane <tgl@sss.pgh.pa.us>2001-01-02 04:33:24 +0000
committerTom Lane <tgl@sss.pgh.pa.us>2001-01-02 04:33:24 +0000
commit1b8a219eefb9235f0fdc8ebc2afb6887932dce02 (patch)
tree43c737a565c2f2b3fde74e5507104f8d6d96a49a /src/backend/access/transam/xlogutils.c
parent25d88e4c53e4249f3ba033d7f1b424396c5b65b0 (diff)
downloadpostgresql-1b8a219eefb9235f0fdc8ebc2afb6887932dce02.tar.gz
postgresql-1b8a219eefb9235f0fdc8ebc2afb6887932dce02.zip
Clean up non-reentrant interface for hash_seq/HashTableWalk, so that
starting a new hashtable search no longer clobbers any other search active anywhere in the system. Fix RelationCacheInvalidate() so that it will not crash or go into an infinite loop if invoked recursively, as for example by a second SI Reset message arriving while we are still processing a prior one.
Diffstat (limited to 'src/backend/access/transam/xlogutils.c')
-rw-r--r--src/backend/access/transam/xlogutils.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/backend/access/transam/xlogutils.c b/src/backend/access/transam/xlogutils.c
index acd19da263c..1447fa29a54 100644
--- a/src/backend/access/transam/xlogutils.c
+++ b/src/backend/access/transam/xlogutils.c
@@ -262,7 +262,7 @@ _xl_init_rel_cache(void)
}
static void
-_xl_remove_hash_entry(XLogRelDesc **edata, int dummy)
+_xl_remove_hash_entry(XLogRelDesc **edata, Datum dummy)
{
XLogRelCacheEntry *hentry;
bool found;
@@ -328,7 +328,7 @@ XLogCloseRelationCache(void)
if (!_xlrelarr)
return;
- HashTableWalk(_xlrelcache, (HashtFunc)_xl_remove_hash_entry, 0);
+ HashTableWalk(_xlrelcache, (HashtFunc) _xl_remove_hash_entry, 0);
hash_destroy(_xlrelcache);
free(_xlrelarr);