diff options
author | Robert Haas <rhaas@postgresql.org> | 2017-02-07 16:20:05 -0500 |
---|---|---|
committer | Robert Haas <rhaas@postgresql.org> | 2017-02-07 16:20:05 -0500 |
commit | ac8eb972f268c787bfe7579b1747c3866fced5a9 (patch) | |
tree | 2d604f2a655ebe9b21485eb23437bf65f4507578 | |
parent | 565903af474e85cef28ff712d773f13b6701ded5 (diff) | |
download | postgresql-ac8eb972f268c787bfe7579b1747c3866fced5a9.tar.gz postgresql-ac8eb972f268c787bfe7579b1747c3866fced5a9.zip |
Avoid redefining simplehash_allocate/simplehash_free.
There's no generic guard against multiple inclusion in this file,
for good reason. But these typedefs need one, as per a report
from Jeff Janes.
-rw-r--r-- | src/include/lib/simplehash.h | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/src/include/lib/simplehash.h b/src/include/lib/simplehash.h index fd7063c216f..359c7b8aa0c 100644 --- a/src/include/lib/simplehash.h +++ b/src/include/lib/simplehash.h @@ -88,8 +88,11 @@ #define SH_ENTRY_HASH SH_MAKE_NAME(entry_hash) /* Allocation function for hash table elements */ +#ifndef SIMPLEHASH_TYPEDEFS +#define SIMPLEHASH_TYPEDEFS typedef void *(*simplehash_allocate) (Size size, void *args); typedef void (*simplehash_free) (void *pointer, void *args); +#endif /* generate forward declarations necessary to use the hash table */ #ifdef SH_DECLARE |