diff options
author | Heikki Linnakangas | 2024-02-23 15:39:27 +0000 |
---|---|---|
committer | Heikki Linnakangas | 2024-02-23 15:39:27 +0000 |
commit | d360e3cc60e37d6d41ee78acf7bd5cb313b978c1 (patch) | |
tree | 670ffb58e2c0d6810b72144846fdc07d5f233d4c | |
parent | 8af256524893987a3e534c6578dd60edfb782a77 (diff) |
Fix compiler warning on typedef redeclaration
bulk_write.c:78:3: error: redefinition of typedef 'BulkWriteState' is a C11 feature [-Werror,-Wtypedef-redefinition]
} BulkWriteState;
^
../../../../src/include/storage/bulk_write.h:20:31: note: previous definition is here
typedef struct BulkWriteState BulkWriteState;
^
1 error generated.
Per buildfarm animals 'sifaka' and 'longfin'.
Discussion: https://www.postgresql.org/message-id/[email protected]
-rw-r--r-- | src/backend/storage/smgr/bulk_write.c | 4 | ||||
-rw-r--r-- | src/include/storage/bulk_write.h | 1 |
2 files changed, 3 insertions, 2 deletions
diff --git a/src/backend/storage/smgr/bulk_write.c b/src/backend/storage/smgr/bulk_write.c index 04a76ec5e36..4a10ece4c39 100644 --- a/src/backend/storage/smgr/bulk_write.c +++ b/src/backend/storage/smgr/bulk_write.c @@ -57,7 +57,7 @@ typedef struct PendingWrite /* * Bulk writer state for one relation fork. */ -typedef struct BulkWriteState +struct BulkWriteState { /* Information about the target relation we're writing */ SMgrRelation smgr; @@ -75,7 +75,7 @@ typedef struct BulkWriteState XLogRecPtr start_RedoRecPtr; MemoryContext memcxt; -} BulkWriteState; +}; static void smgr_bulk_flush(BulkWriteState *bulkstate); diff --git a/src/include/storage/bulk_write.h b/src/include/storage/bulk_write.h index 6d4532d05e1..cf6f6fcb3f2 100644 --- a/src/include/storage/bulk_write.h +++ b/src/include/storage/bulk_write.h @@ -17,6 +17,7 @@ #include "storage/smgr.h" #include "utils/rel.h" +/* Bulk writer state, contents are private to bulk_write.c */ typedef struct BulkWriteState BulkWriteState; /* |