diff options
| author | Bruce Momjian | 2017-05-17 20:31:56 +0000 |
|---|---|---|
| committer | Bruce Momjian | 2017-05-17 20:31:56 +0000 |
| commit | a6fd7b7a5f7bf3a8aa3f3d076cf09d922c1c6dd2 (patch) | |
| tree | d10454411c05d459abe06df161ab3c1156c5f477 /src/include | |
| parent | 8a943324780259757c77c56cfc597347d1150cdb (diff) | |
Post-PG 10 beta1 pgindent run
perltidy run not included.
Diffstat (limited to 'src/include')
70 files changed, 382 insertions, 371 deletions
diff --git a/src/include/access/brin.h b/src/include/access/brin.h index e03aa08f608..45d55a97338 100644 --- a/src/include/access/brin.h +++ b/src/include/access/brin.h @@ -31,8 +31,8 @@ typedef struct BrinOptions */ typedef struct BrinStatsData { - BlockNumber pagesPerRange; - BlockNumber revmapNumPages; + BlockNumber pagesPerRange; + BlockNumber revmapNumPages; } BrinStatsData; diff --git a/src/include/access/brin_tuple.h b/src/include/access/brin_tuple.h index b042fa8d50b..3f4a7b6d3cd 100644 --- a/src/include/access/brin_tuple.h +++ b/src/include/access/brin_tuple.h @@ -39,9 +39,9 @@ typedef struct BrinMemTuple BlockNumber bt_blkno; /* heap blkno that the tuple is for */ MemoryContext bt_context; /* memcxt holding the bt_columns values */ /* output arrays for brin_deform_tuple: */ - Datum *bt_values; /* values array */ - bool *bt_allnulls; /* allnulls array */ - bool *bt_hasnulls; /* hasnulls array */ + Datum *bt_values; /* values array */ + bool *bt_allnulls; /* allnulls array */ + bool *bt_hasnulls; /* hasnulls array */ /* not an output array, but must be last */ BrinValues bt_columns[FLEXIBLE_ARRAY_MEMBER]; } BrinMemTuple; diff --git a/src/include/access/brin_xlog.h b/src/include/access/brin_xlog.h index e08f9d73025..38e6dcccf22 100644 --- a/src/include/access/brin_xlog.h +++ b/src/include/access/brin_xlog.h @@ -132,7 +132,7 @@ typedef struct xl_brin_revmap_extend */ typedef struct xl_brin_desummarize { - BlockNumber pagesPerRange; + BlockNumber pagesPerRange; /* page number location to set to invalid */ BlockNumber heapBlk; /* offset of item to delete in regular index page */ diff --git a/src/include/access/clog.h b/src/include/access/clog.h index 60a9e11a0fa..5ac7cdd6184 100644 --- a/src/include/access/clog.h +++ b/src/include/access/clog.h @@ -30,9 +30,9 @@ typedef int XidStatus; typedef struct xl_clog_truncate { - int pageno; + int pageno; TransactionId oldestXact; - Oid oldestXactDb; + Oid oldestXactDb; } xl_clog_truncate; extern void TransactionIdSetTreeStatus(TransactionId xid, int nsubxids, diff --git a/src/include/access/hash.h b/src/include/access/hash.h index adba224008c..3a210a876b0 100644 --- a/src/include/access/hash.h +++ b/src/include/access/hash.h @@ -57,7 +57,7 @@ typedef uint32 Bucket; #define LH_BUCKET_BEING_POPULATED (1 << 4) #define LH_BUCKET_BEING_SPLIT (1 << 5) #define LH_BUCKET_NEEDS_SPLIT_CLEANUP (1 << 6) -#define LH_PAGE_HAS_DEAD_TUPLES (1 << 7) +#define LH_PAGE_HAS_DEAD_TUPLES (1 << 7) #define LH_PAGE_TYPE \ (LH_OVERFLOW_PAGE | LH_BUCKET_PAGE | LH_BITMAP_PAGE | LH_META_PAGE) @@ -97,7 +97,7 @@ typedef HashPageOpaqueData *HashPageOpaque; */ #define HASHO_PAGE_ID 0xFF80 -typedef struct HashScanPosItem /* what we remember about each match */ +typedef struct HashScanPosItem /* what we remember about each match */ { ItemPointerData heapTid; /* TID of referenced heap item */ OffsetNumber indexOffset; /* index item's location within page */ @@ -145,8 +145,9 @@ typedef struct HashScanOpaqueData */ bool hashso_buc_split; /* info about killed items if any (killedItems is NULL if never used) */ - HashScanPosItem *killedItems; /* tids and offset numbers of killed items */ - int numKilled; /* number of currently stored items */ + HashScanPosItem *killedItems; /* tids and offset numbers of killed + * items */ + int numKilled; /* number of currently stored items */ } HashScanOpaqueData; typedef HashScanOpaqueData *HashScanOpaque; @@ -358,7 +359,7 @@ extern Buffer _hash_getbucketbuf_from_hashkey(Relation rel, uint32 hashkey, HashMetaPage *cachedmetap); extern Buffer _hash_getinitbuf(Relation rel, BlockNumber blkno); extern void _hash_initbuf(Buffer buf, uint32 max_bucket, uint32 num_bucket, - uint32 flag, bool initpage); + uint32 flag, bool initpage); extern Buffer _hash_getnewbuf(Relation rel, BlockNumber blkno, ForkNumber forkNum); extern Buffer _hash_getbuf_with_strategy(Relation rel, BlockNumber blkno, diff --git a/src/include/access/hash_xlog.h b/src/include/access/hash_xlog.h index 644da2eaf22..d4a6a71ca7a 100644 --- a/src/include/access/hash_xlog.h +++ b/src/include/access/hash_xlog.h @@ -44,7 +44,8 @@ #define XLOG_HASH_UPDATE_META_PAGE 0xB0 /* update meta page after * vacuum */ -#define XLOG_HASH_VACUUM_ONE_PAGE 0xC0 /* remove dead tuples from index page */ +#define XLOG_HASH_VACUUM_ONE_PAGE 0xC0 /* remove dead tuples from + * index page */ /* * xl_hash_split_allocate_page flag values, 8 bits are available. @@ -76,7 +77,7 @@ typedef struct xl_hash_createidx typedef struct xl_hash_insert { OffsetNumber offnum; -} xl_hash_insert; +} xl_hash_insert; #define SizeOfHashInsert (offsetof(xl_hash_insert, offnum) + sizeof(OffsetNumber)) @@ -95,7 +96,7 @@ typedef struct xl_hash_add_ovfl_page { uint16 bmsize; bool bmpage_found; -} xl_hash_add_ovfl_page; +} xl_hash_add_ovfl_page; #define SizeOfHashAddOvflPage \ (offsetof(xl_hash_add_ovfl_page, bmpage_found) + sizeof(bool)) @@ -115,7 +116,7 @@ typedef struct xl_hash_split_allocate_page uint16 old_bucket_flag; uint16 new_bucket_flag; uint8 flags; -} xl_hash_split_allocate_page; +} xl_hash_split_allocate_page; #define SizeOfHashSplitAllocPage \ (offsetof(xl_hash_split_allocate_page, flags) + sizeof(uint8)) @@ -132,7 +133,7 @@ typedef struct xl_hash_split_complete { uint16 old_bucket_flag; uint16 new_bucket_flag; -} xl_hash_split_complete; +} xl_hash_split_complete; #define SizeOfHashSplitComplete \ (offsetof(xl_hash_split_complete, new_bucket_flag) + sizeof(uint16)) @@ -153,7 +154,7 @@ typedef struct xl_hash_move_page_contents bool is_prim_bucket_same_wrt; /* TRUE if the page to which * tuples are moved is same as * primary bucket page */ -} xl_hash_move_page_contents; +} xl_hash_move_page_contents; #define SizeOfHashMovePageContents \ (offsetof(xl_hash_move_page_contents, is_prim_bucket_same_wrt) + sizeof(bool)) @@ -182,7 +183,7 @@ typedef struct xl_hash_squeeze_page * tuples are moved is the * page previous to the freed * overflow page */ -} xl_hash_squeeze_page; +} xl_hash_squeeze_page; #define SizeOfHashSqueezePage \ (offsetof(xl_hash_squeeze_page, is_prev_bucket_same_wrt) + sizeof(bool)) @@ -201,7 +202,7 @@ typedef struct xl_hash_delete * LH_PAGE_HAS_DEAD_TUPLES flag */ bool is_primary_bucket_page; /* TRUE if the operation is for * primary bucket page */ -} xl_hash_delete; +} xl_hash_delete; #define SizeOfHashDelete (offsetof(xl_hash_delete, is_primary_bucket_page) + sizeof(bool)) @@ -215,7 +216,7 @@ typedef struct xl_hash_delete typedef struct xl_hash_update_meta_page { double ntuples; -} xl_hash_update_meta_page; +} xl_hash_update_meta_page; #define SizeOfHashUpdateMetaPage \ (offsetof(xl_hash_update_meta_page, ntuples) + sizeof(double)) @@ -232,7 +233,7 @@ typedef struct xl_hash_init_meta_page double num_tuples; RegProcedure procid; uint16 ffactor; -} xl_hash_init_meta_page; +} xl_hash_init_meta_page; #define SizeOfHashInitMetaPage \ (offsetof(xl_hash_init_meta_page, ffactor) + sizeof(uint16)) @@ -248,7 +249,7 @@ typedef struct xl_hash_init_meta_page typedef struct xl_hash_init_bitmap_page { uint16 bmsize; -} xl_hash_init_bitmap_page; +} xl_hash_init_bitmap_page; #define SizeOfHashInitBitmapPage \ (offsetof(xl_hash_init_bitmap_page, bmsize) + sizeof(uint16)) @@ -264,13 +265,13 @@ typedef struct xl_hash_init_bitmap_page */ typedef struct xl_hash_vacuum_one_page { - RelFileNode hnode; - int ntuples; + RelFileNode hnode; + int ntuples; /* TARGET OFFSET NUMBERS FOLLOW AT THE END */ -} xl_hash_vacuum_one_page; +} xl_hash_vacuum_one_page; -#define SizeOfHashVacuumOnePage \ +#define SizeOfHashVacuumOnePage \ (offsetof(xl_hash_vacuum_one_page, ntuples) + sizeof(int)) extern void hash_redo(XLogReaderState *record); diff --git a/src/include/access/relscan.h b/src/include/access/relscan.h index 3fc726d712f..f4d4f1ee719 100644 --- a/src/include/access/relscan.h +++ b/src/include/access/relscan.h @@ -146,7 +146,7 @@ typedef struct ParallelIndexScanDescData Oid ps_indexid; Size ps_offset; /* Offset in bytes of am specific structure */ char ps_snapshot_data[FLEXIBLE_ARRAY_MEMBER]; -} ParallelIndexScanDescData; +} ParallelIndexScanDescData; /* Struct for heap-or-index scans of system tables */ typedef struct SysScanDescData diff --git a/src/include/access/twophase.h b/src/include/access/twophase.h index 80ec4ca4a5d..2aab1f93a65 100644 --- a/src/include/access/twophase.h +++ b/src/include/access/twophase.h @@ -54,7 +54,7 @@ extern void CheckPointTwoPhase(XLogRecPtr redo_horizon); extern void FinishPreparedTransaction(const char *gid, bool isCommit); extern void PrepareRedoAdd(char *buf, XLogRecPtr start_lsn, - XLogRecPtr end_lsn); + XLogRecPtr end_lsn); extern void PrepareRedoRemove(TransactionId xid, bool giveWarning); extern void restoreTwoPhaseData(void); #endif /* TWOPHASE_H */ diff --git a/src/include/access/xact.h b/src/include/access/xact.h index 5b37c058427..7eb85b72df2 100644 --- a/src/include/access/xact.h +++ b/src/include/access/xact.h @@ -78,7 +78,7 @@ extern int synchronous_commit; * globally accessible, so can be set from anywhere in the code which requires * recording flags. */ -extern int MyXactFlags; +extern int MyXactFlags; /* * XACT_FLAGS_ACCESSEDTEMPREL - set when a temporary relation is accessed. We diff --git a/src/include/access/xlog.h b/src/include/access/xlog.h index 4d9773459de..e00ab12d2ee 100644 --- a/src/include/access/xlog.h +++ b/src/include/access/xlog.h @@ -221,8 +221,8 @@ extern CheckpointStatsData CheckpointStats; struct XLogRecData; extern XLogRecPtr XLogInsertRecord(struct XLogRecData *rdata, - XLogRecPtr fpw_lsn, - uint8 flags); + XLogRecPtr fpw_lsn, + uint8 flags); extern void XLogFlush(XLogRecPtr RecPtr); extern bool XLogBackgroundFlush(void); extern bool XLogNeedsFlush(XLogRecPtr RecPtr); diff --git a/src/include/access/xlogreader.h b/src/include/access/xlogreader.h index a1beeb54965..956c9bd3a86 100644 --- a/src/include/access/xlogreader.h +++ b/src/include/access/xlogreader.h @@ -163,15 +163,17 @@ struct XLogReaderState XLogRecPtr currRecPtr; /* timeline to read it from, 0 if a lookup is required */ TimeLineID currTLI; + /* * Safe point to read to in currTLI if current TLI is historical * (tliSwitchPoint) or InvalidXLogRecPtr if on current timeline. * - * Actually set to the start of the segment containing the timeline - * switch that ends currTLI's validity, not the LSN of the switch - * its self, since we can't assume the old segment will be present. + * Actually set to the start of the segment containing the timeline switch + * that ends currTLI's validity, not the LSN of the switch its self, since + * we can't assume the old segment will be present. */ XLogRecPtr currTLIValidUntil; + /* * If currTLI is not the most recent known timeline, the next timeline to * read from when currTLIValidUntil is reached. diff --git a/src/include/access/xlogutils.h b/src/include/access/xlogutils.h index 25a99422c1a..114ffbcc539 100644 --- a/src/include/access/xlogutils.h +++ b/src/include/access/xlogutils.h @@ -53,6 +53,6 @@ extern int read_local_xlog_page(XLogReaderState *state, TimeLineID *pageTLI); extern void XLogReadDetermineTimeline(XLogReaderState *state, - XLogRecPtr wantPage, uint32 wantLength); + XLogRecPtr wantPage, uint32 wantLength); #endif diff --git a/src/include/c.h b/src/include/c.h index fba07c651f8..10953b31723 100644 --- a/src/include/c.h +++ b/src/include/c.h @@ -420,7 +420,7 @@ typedef uint32 CommandId; typedef struct { int indx[MAXDIM]; -} IntArray; +} IntArray; /* ---------------- * Variable-length datatypes all share the 'struct varlena' header. diff --git a/src/include/catalog/dependency.h b/src/include/catalog/dependency.h index 33361ffce9e..8586b9d7a1f 100644 --- a/src/include/catalog/dependency.h +++ b/src/include/catalog/dependency.h @@ -240,7 +240,7 @@ extern Oid getExtensionOfObject(Oid classId, Oid objectId); extern bool sequenceIsOwned(Oid seqId, char deptype, Oid *tableId, int32 *colId); extern List *getOwnedSequences(Oid relid, AttrNumber attnum); -extern Oid getOwnedSequence(Oid relid, AttrNumber attnum); +extern Oid getOwnedSequence(Oid relid, AttrNumber attnum); extern Oid get_constraint_index(Oid constraintId); diff --git a/src/include/catalog/pg_authid.h b/src/include/catalog/pg_authid.h index 82524242e19..39fea9f41ac 100644 --- a/src/include/catalog/pg_authid.h +++ b/src/include/catalog/pg_authid.h @@ -105,7 +105,7 @@ DATA(insert OID = 3373 ( "pg_monitor" f t f f f f f -1 _null_ _null_)); DATA(insert OID = 3374 ( "pg_read_all_settings" f t f f f f f -1 _null_ _null_)); #define DEFAULT_ROLE_READ_ALL_SETTINGS 3374 DATA(insert OID = 3375 ( "pg_read_all_stats" f t f f f f f -1 _null_ _null_)); -#define DEFAULT_ROLE_READ_ALL_STATS 3375 +#define DEFAULT_ROLE_READ_ALL_STATS 3375 DATA(insert OID = 3377 ( "pg_stat_scan_tables" f t f f f f f -1 _null_ _null_)); #define DEFAULT_ROLE_STAT_SCAN_TABLES 3377 DATA(insert OID = 4200 ( "pg_signal_backend" f t f f f f f -1 _null_ _null_)); diff --git a/src/include/catalog/pg_collation.h b/src/include/catalog/pg_collation.h index 8edd8aa0662..1e44ce0949c 100644 --- a/src/include/catalog/pg_collation.h +++ b/src/include/catalog/pg_collation.h @@ -39,7 +39,8 @@ CATALOG(pg_collation,3456) NameData collcollate; /* LC_COLLATE setting */ NameData collctype; /* LC_CTYPE setting */ #ifdef CATALOG_VARLEN /* variable-length fields start here */ - text collversion; /* provider-dependent version of collation data */ + text collversion; /* provider-dependent version of collation + * data */ #endif } FormData_pg_collation; diff --git a/src/include/catalog/pg_operator.h b/src/include/catalog/pg_operator.h index fe8795ac8bf..ccbb17efecd 100644 --- a/src/include/catalog/pg_operator.h +++ b/src/include/catalog/pg_operator.h @@ -1847,7 +1847,7 @@ DATA(insert OID = 3284 ( "||" PGNSP PGUID b f f 3802 3802 3802 0 0 jsonb_con DESCR("concatenate"); DATA(insert OID = 3285 ( "-" PGNSP PGUID b f f 3802 25 3802 0 0 3302 - - )); DESCR("delete object field"); -DATA(insert OID = 3398 ( "-" PGNSP PGUID b f f 3802 1009 3802 0 0 3343 - -)); +DATA(insert OID = 3398 ( "-" PGNSP PGUID b f f 3802 1009 3802 0 0 3343 - -)); DESCR("delete object fields"); DATA(insert OID = 3286 ( "-" PGNSP PGUID b f f 3802 23 3802 0 0 3303 - - )); DESCR("delete array element"); diff --git a/src/include/catalog/pg_policy.h b/src/include/catalog/pg_policy.h index f8dc2ccf158..331584f5e06 100644 --- a/src/include/catalog/pg_policy.h +++ b/src/include/catalog/pg_policy.h @@ -50,6 +50,6 @@ typedef FormData_pg_policy *Form_pg_policy; #define Anum_pg_policy_polpermissive 4 #define Anum_pg_policy_polroles 5 #define Anum_pg_policy_polqual 6 -#define Anum_pg_policy_polwithcheck 7 +#define Anum_pg_policy_polwithcheck 7 #endif /* PG_POLICY_H */ diff --git a/src/include/catalog/pg_proc.h b/src/include/catalog/pg_proc.h index 5c38ab55ec5..460cdb9ed81 100644 --- a/src/include/catalog/pg_proc.h +++ b/src/include/catalog/pg_proc.h @@ -1774,7 +1774,7 @@ DATA(insert OID = 1765 ( setval PGNSP PGUID 12 1 0 0 0 f f f f t f v u 3 0 20 DESCR("set sequence value and is_called status"); DATA(insert OID = 3078 ( pg_sequence_parameters PGNSP PGUID 12 1 0 0 0 f f f f t f s s 1 0 2249 "26" "{26,20,20,20,20,16,20,26}" "{i,o,o,o,o,o,o,o}" "{sequence_oid,start_value,minimum_value,maximum_value,increment,cycle_option,cache_size,data_type}" _null_ _null_ pg_sequence_parameters _null_ _null_ _null_)); DESCR("sequence parameters, for use by information schema"); -DATA(insert OID = 4032 ( pg_sequence_last_value PGNSP PGUID 12 1 0 0 0 f f f f t f v u 1 0 20 "2205" _null_ _null_ _null_ _null_ _null_ pg_sequence_last_value _null_ _null_ _null_ )); +DATA(insert OID = 4032 ( pg_sequence_last_value PGNSP PGUID 12 1 0 0 0 f f f f t f v u 1 0 20 "2205" _null_ _null_ _null_ _null_ _null_ pg_sequence_last_value _null_ _null_ _null_ )); DESCR("sequence last value"); DATA(insert OID = 1579 ( varbit_in PGNSP PGUID 12 1 0 0 0 f f f f t f i s 3 0 1562 "2275 26 23" _null_ _null_ _null_ _null_ _null_ varbit_in _null_ _null_ _null_ )); @@ -1992,7 +1992,7 @@ DATA(insert OID = 3415 ( pg_get_statisticsobjdef PGNSP PGUID 12 1 0 0 0 f f DESCR("extended statistics object description"); DATA(insert OID = 3352 ( pg_get_partkeydef PGNSP PGUID 12 1 0 0 0 f f f f t f s s 1 0 25 "26" _null_ _null_ _null_ _null_ _null_ pg_get_partkeydef _null_ _null_ _null_ )); DESCR("partition key description"); -DATA(insert OID = 3408 ( pg_get_partition_constraintdef PGNSP PGUID 12 1 0 0 0 f f f f t f s s 1 0 25 "26" _null_ _null_ _null_ _null_ _null_ pg_get_partition_constraintdef _null_ _null_ _null_ )); +DATA(insert OID = 3408 ( pg_get_partition_constraintdef PGNSP PGUID 12 1 0 0 0 f f f f t f s s 1 0 25 "26" _null_ _null_ _null_ _null_ _null_ pg_get_partition_constraintdef _null_ _null_ _null_ )); DESCR("partition constraint description"); DATA(insert OID = 1662 ( pg_get_triggerdef PGNSP PGUID 12 1 0 0 0 f f f f t f s s 1 0 25 "26" _null_ _null_ _null_ _null_ _null_ pg_get_triggerdef _null_ _null_ _null_ )); DESCR("trigger description"); @@ -2029,7 +2029,7 @@ DESCR("is a relation insertable/updatable/deletable"); DATA(insert OID = 3843 ( pg_column_is_updatable PGNSP PGUID 12 10 0 0 0 f f f f t f s s 3 0 16 "2205 21 16" _null_ _null_ _null_ _null_ _null_ pg_column_is_updatable _null_ _null_ _null_ )); DESCR("is a column updatable"); -DATA(insert OID = 6120 ( pg_get_replica_identity_index PGNSP PGUID 12 10 0 0 0 f f f f t f s s 1 0 2205 "2205" _null_ _null_ _null_ _null_ _null_ pg_get_replica_identity_index _null_ _null_ _null_ )); +DATA(insert OID = 6120 ( pg_get_replica_identity_index PGNSP PGUID 12 10 0 0 0 f f f f t f s s 1 0 2205 "2205" _null_ _null_ _null_ _null_ _null_ pg_get_replica_identity_index _null_ _null_ _null_ )); DESCR("oid of replica identity index if any"); /* Deferrable unique constraint trigger */ @@ -3219,7 +3219,7 @@ DATA(insert OID = 2848 ( pg_switch_wal PGNSP PGUID 12 1 0 0 0 f f f f t f v s DESCR("switch to new wal file"); DATA(insert OID = 3098 ( pg_create_restore_point PGNSP PGUID 12 1 0 0 0 f f f f t f v s 1 0 3220 "25" _null_ _null_ _null_ _null_ _null_ pg_create_restore_point _null_ _null_ _null_ )); DESCR("create a named restore point"); -DATA(insert OID = 2849 ( pg_current_wal_lsn PGNSP PGUID 12 1 0 0 0 f f f f t f v s 0 0 3220 "" _null_ _null_ _null_ _null_ _null_ pg_current_wal_lsn _null_ _null_ _null_ )); +DATA(insert OID = 2849 ( pg_current_wal_lsn PGNSP PGUID 12 1 0 0 0 f f f f t f v s 0 0 3220 "" _null_ _null_ _null_ _null_ _null_ pg_current_wal_lsn _null_ _null_ _null_ )); DESCR("current wal write location"); DATA(insert OID = 2852 ( pg_current_wal_insert_lsn PGNSP PGUID 12 1 0 0 0 f f f f t f v s 0 0 3220 "" _null_ _null_ _null_ _null_ _null_ pg_current_wal_insert_lsn _null_ _null_ _null_ )); DESCR("current wal insert location"); @@ -3241,7 +3241,7 @@ DESCR("true if server is in recovery"); DATA(insert OID = 3820 ( pg_last_wal_receive_lsn PGNSP PGUID 12 1 0 0 0 f f f f t f v s 0 0 3220 "" _null_ _null_ _null_ _null_ _null_ pg_last_wal_receive_lsn _null_ _null_ _null_ )); DESCR("current wal flush location"); -DATA(insert OID = 3821 ( pg_last_wal_replay_lsn PGNSP PGUID 12 1 0 0 0 f f f f t f v s 0 0 3220 "" _null_ _null_ _null_ _null_ _null_ pg_last_wal_replay_lsn _null_ _null_ _null_ )); +DATA(insert OID = 3821 ( pg_last_wal_replay_lsn PGNSP PGUID 12 1 0 0 0 f f f f t f v s 0 0 3220 "" _null_ _null_ _null_ _null_ _null_ pg_last_wal_replay_lsn _null_ _null_ _null_ )); DESCR("last wal replay location"); DATA(insert OID = 3830 ( pg_last_xact_replay_timestamp PGNSP PGUID 12 1 0 0 0 f f f f t f v s 0 0 1184 "" _null_ _null_ _null_ _null_ _null_ pg_last_xact_replay_timestamp _null_ _null_ _null_ )); DESCR("timestamp of last replay xact"); @@ -3257,9 +3257,9 @@ DATA(insert OID = 2621 ( pg_reload_conf PGNSP PGUID 12 1 0 0 0 f f f f t f v s DESCR("reload configuration files"); DATA(insert OID = 2622 ( pg_rotate_logfile PGNSP PGUID 12 1 0 0 0 f f f f t f v s 0 0 16 "" _null_ _null_ _null_ _null_ _null_ pg_rotate_logfile _null_ _null_ _null_ )); DESCR("rotate log file"); -DATA(insert OID = 3800 ( pg_current_logfile PGNSP PGUID 12 1 0 0 0 f f f f f f v s 0 0 25 "" _null_ _null_ _null_ _null_ _null_ pg_current_logfile _null_ _null_ _null_ )); +DATA(insert OID = 3800 ( pg_current_logfile PGNSP PGUID 12 1 0 0 0 f f f f f f v s 0 0 25 "" _null_ _null_ _null_ _null_ _null_ pg_current_logfile _null_ _null_ _null_ )); DESCR("current logging collector file location"); -DATA(insert OID = 3801 ( pg_current_logfile PGNSP PGUID 12 1 0 0 0 f f f f f f v s 1 0 25 "25" _null_ _null_ _null_ _null_ _null_ pg_current_logfile_1arg _null_ _null_ _null_ )); +DATA(insert OID = 3801 ( pg_current_logfile PGNSP PGUID 12 1 0 0 0 f f f f f f v s 1 0 25 "25" _null_ _null_ _null_ _null_ _null_ pg_current_logfile_1arg _null_ _null_ _null_ )); DESCR("current logging collector file location"); DATA(insert OID = 2623 ( pg_stat_file PGNSP PGUID 12 1 0 0 0 f f f f t f v s 1 0 2249 "25" "{25,20,1184,1184,1184,1184,16}" "{i,o,o,o,o,o,o}" "{filename,size,access,modification,change,creation,isdir}" _null_ _null_ pg_stat_file_1arg _null_ _null_ _null_ )); @@ -5007,7 +5007,7 @@ DESCR("GIN support"); DATA(insert OID = 3301 ( jsonb_concat PGNSP PGUID 12 1 0 0 0 f f f f t f i s 2 0 3802 "3802 3802" _null_ _null_ _null_ _null_ _null_ jsonb_concat _null_ _null_ _null_ )); DATA(insert OID = 3302 ( jsonb_delete PGNSP PGUID 12 1 0 0 0 f f f f t f i s 2 0 3802 "3802 25" _null_ _null_ _null_ _null_ _null_ jsonb_delete _null_ _null_ _null_ )); DATA(insert OID = 3303 ( jsonb_delete PGNSP PGUID 12 1 0 0 0 f f f f t f i s 2 0 3802 "3802 23" _null_ _null_ _null_ _null_ _null_ jsonb_delete_idx _null_ _null_ _null_ )); -DATA(insert OID = 3343 ( jsonb_delete PGNSP PGUID 12 1 0 25 0 f f f f t f i s 2 0 3802 "3802 1009" "{3802,1009}" "{i,v}" "{from_json,path_elems}" _null_ _null_ jsonb_delete_array _null_ _null_ _null_ )); +DATA(insert OID = 3343 ( jsonb_delete PGNSP PGUID 12 1 0 25 0 f f f f t f i s 2 0 3802 "3802 1009" "{3802,1009}" "{i,v}" "{from_json,path_elems}" _null_ _null_ jsonb_delete_array _null_ _null_ _null_ )); DATA(insert OID = 3304 ( jsonb_delete_path PGNSP PGUID 12 1 0 0 0 f f f f t f i s 2 0 3802 "3802 1009" _null_ _null_ _null_ _null_ _null_ jsonb_delete_path _null_ _null_ _null_ )); DATA(insert OID = 3305 ( jsonb_set PGNSP PGUID 12 1 0 0 0 f f f f t f i s 4 0 3802 "3802 1009 3802 16" _null_ _null_ _null_ _null_ _null_ jsonb_set _null_ _null_ _null_ )); DESCR("Set part of a jsonb"); @@ -5467,9 +5467,9 @@ DATA(insert OID = 3448 ( pg_collation_actual_version PGNSP PGUID 12 100 0 0 0 f DESCR("import collations from operating system"); /* system management/monitoring related functions */ -DATA(insert OID = 3353 ( pg_ls_logdir PGNSP PGUID 12 10 20 0 0 f f f f t t v s 0 0 2249 "" "{25,20,1184}" "{o,o,o}" "{name,size,modification}" _null_ _null_ pg_ls_logdir _null_ _null_ _null_ )); +DATA(insert OID = 3353 ( pg_ls_logdir PGNSP PGUID 12 10 20 0 0 f f f f t t v s 0 0 2249 "" "{25,20,1184}" "{o,o,o}" "{name,size,modification}" _null_ _null_ pg_ls_logdir _null_ _null_ _null_ )); DESCR("list files in the log directory"); -DATA(insert OID = 3354 ( pg_ls_waldir PGNSP PGUID 12 10 20 0 0 f f f f t t v s 0 0 2249 "" "{25,20,1184}" "{o,o,o}" "{name,size,modification}" _null_ _null_ pg_ls_waldir _null_ _null_ _null_ )); +DATA(insert OID = 3354 ( pg_ls_waldir PGNSP PGUID 12 10 20 0 0 f f f f t t v s 0 0 2249 "" "{25,20,1184}" "{o,o,o}" "{name,size,modification}" _null_ _null_ pg_ls_waldir _null_ _null_ _null_ )); DESCR("list of files in the WAL directory"); /* diff --git a/src/include/catalog/pg_publication.h b/src/include/catalog/pg_publication.h index f3c4f3932be..c2086c1f42e 100644 --- a/src/include/catalog/pg_publication.h +++ b/src/include/catalog/pg_publication.h @@ -30,13 +30,13 @@ CATALOG(pg_publication,6104) { - NameData pubname; /* name of the publication */ + NameData pubname; /* name of the publication */ - Oid pubowner; /* publication owner */ + Oid pubowner; /* publication owner */ /* - * indicates that this is special publication which should encompass - * all tables in the database (except for the unlogged and temp ones) + * indicates that this is special publication which should encompass all + * tables in the database (except for the unlogged and temp ones) */ bool puballtables; @@ -73,16 +73,16 @@ typedef FormData_pg_publication *Form_pg_publication; typedef struct PublicationActions { - bool pubinsert; - bool pubupdate; - bool pubdelete; + bool pubinsert; + bool pubupdate; + bool pubdelete; } PublicationActions; typedef struct Publication { - Oid oid; - char *name; - bool alltables; + Oid oid; + char *name; + bool alltables; PublicationActions pubactions; } Publication; @@ -94,9 +94,9 @@ extern List *GetAllTablesPublications(void); extern List *GetAllTablesPublicationRelations(void); extern ObjectAddress publication_add_relation(Oid pubid, Relation targetrel, - bool if_not_exists); + bool if_not_exists); -extern Oid get_publication_oid(const char *pubname, bool missing_ok); +extern Oid get_publication_oid(const char *pubname, bool missing_ok); extern char *get_publication_name(Oid pubid); extern Datum pg_get_publication_tables(PG_FUNCTION_ARGS); diff --git a/src/include/catalog/pg_publication_rel.h b/src/include/catalog/pg_publication_rel.h index 32218a748db..f889b6f4db2 100644 --- a/src/include/catalog/pg_publication_rel.h +++ b/src/include/catalog/pg_publication_rel.h @@ -29,8 +29,8 @@ CATALOG(pg_publication_rel,6106) { - Oid prpubid; /* Oid of the publication */ - Oid prrelid; /* Oid of the relation */ + Oid prpubid; /* Oid of the publication */ + Oid prrelid; /* Oid of the relation */ } FormData_pg_publication_rel; /* ---------------- diff --git a/src/include/catalog/pg_sequence.h b/src/include/catalog/pg_sequence.h index ef15e68a578..26d2993674f 100644 --- a/src/include/catalog/pg_sequence.h +++ b/src/include/catalog/pg_sequence.h @@ -29,4 +29,4 @@ typedef FormData_pg_sequence *Form_pg_sequence; #define Anum_pg_sequence_seqcache 7 #define Anum_pg_sequence_seqcycle 8 -#endif /* PG_SEQUENCE_H */ +#endif /* PG_SEQUENCE_H */ diff --git a/src/include/catalog/pg_statistic_ext.h b/src/include/catalog/pg_statistic_ext.h index f08379699ea..d302b7fc01f 100644 --- a/src/include/catalog/pg_statistic_ext.h +++ b/src/include/catalog/pg_statistic_ext.h @@ -45,8 +45,8 @@ CATALOG(pg_statistic_ext,3381) int2vector stxkeys; /* array of column keys */ #ifdef CATALOG_VARLEN - char stxkind[1] BKI_FORCE_NOT_NULL; /* statistic types - * requested to build */ + char stxkind[1] BKI_FORCE_NOT_NULL; /* statistic types requested + * to build */ pg_ndistinct stxndistinct; /* ndistinct coefficients (serialized) */ pg_dependencies stxdependencies; /* dependencies (serialized) */ #endif diff --git a/src/include/catalog/pg_subscription.h b/src/include/catalog/pg_subscription.h index d4f3979e7b9..b2cebd4a4b7 100644 --- a/src/include/catalog/pg_subscription.h +++ b/src/include/catalog/pg_subscription.h @@ -20,7 +20,7 @@ * ---------------- */ #define SubscriptionRelationId 6100 -#define SubscriptionRelation_Rowtype_Id 6101 +#define SubscriptionRelation_Rowtype_Id 6101 /* * Technically, the subscriptions live inside the database, so a shared catalog @@ -37,18 +37,18 @@ CATALOG(pg_subscription,6100) BKI_SHARED_RELATION BKI_ROWTYPE_OID(6101) BKI_SCHE Oid subowner; /* Owner of the subscription */ - bool subenabled; /* True if the subscription is enabled - * (the worker should be running) */ + bool subenabled; /* True if the subscription is enabled (the + * worker should be running) */ #ifdef CATALOG_VARLEN /* variable-length fields start here */ /* Connection string to the publisher */ - text subconninfo BKI_FORCE_NOT_NULL; + text subconninfo BKI_FORCE_NOT_NULL; /* Slot name on publisher */ NameData subslotname; /* Synchronous commit setting for worker */ - text subsynccommit BKI_FORCE_NOT_NULL; + text subsynccommit BKI_FORCE_NOT_NULL; /* List of publications subscribed to */ text subpublications[1] BKI_FORCE_NOT_NULL; @@ -74,22 +74,23 @@ typedef FormData_pg_subscription *Form_pg_subscription; typedef struct Subscription { - Oid oid; /* Oid of the subscription */ - Oid dbid; /* Oid of the database which subscription is in */ - char *name; /* Name of the subscription */ - Oid owner; /* Oid of the subscription owner */ - bool enabled; /* Indicates if the subscription is enabled */ - char *conninfo; /* Connection string to the publisher */ - char *slotname; /* Name of the replication slot */ - char *synccommit; /* Synchronous commit setting for worker */ - List *publications; /* List of publication names to subscribe to */ + Oid oid; /* Oid of the subscription */ + Oid dbid; /* Oid of the database which subscription is + * in */ + char *name; /* Name of the subscription */ + Oid owner; /* Oid of the subscription owner */ + bool enabled; /* Indicates if the subscription is enabled */ + char *conninfo; /* Connection string to the publisher */ + char *slotname; /* Name of the replication slot */ + char *synccommit; /* Synchronous commit setting for worker */ + List *publications; /* List of publication names to subscribe to */ } Subscription; extern Subscription *GetSubscription(Oid subid, bool missing_ok); extern void FreeSubscription(Subscription *sub); -extern Oid get_subscription_oid(const char *subname, bool missing_ok); +extern Oid get_subscription_oid(const char *subname, bool missing_ok); extern char *get_subscription_name(Oid subid); -extern int CountDBSubscriptions(Oid dbid); +extern int CountDBSubscriptions(Oid dbid); #endif /* PG_SUBSCRIPTION_H */ diff --git a/src/include/catalog/pg_subscription_rel.h b/src/include/catalog/pg_subscription_rel.h index f08fb528a26..391f96b76e4 100644 --- a/src/include/catalog/pg_subscription_rel.h +++ b/src/include/catalog/pg_subscription_rel.h @@ -31,8 +31,8 @@ CATALOG(pg_subscription_rel,6102) BKI_WITHOUT_OIDS Oid srsubid; /* Oid of subscription */ Oid srrelid; /* Oid of relation */ char srsubstate; /* state of the relation in subscription */ - pg_lsn srsublsn; /* remote lsn of the state change - * used for synchronization coordination */ + pg_lsn srsublsn; /* remote lsn of the state change used for + * synchronization coordination */ } FormData_pg_subscription_rel; typedef FormData_pg_subscription_rel *Form_pg_subscription_rel; @@ -52,8 +52,10 @@ typedef FormData_pg_subscription_rel *Form_pg_subscription_rel; * ---------------- */ #define SUBREL_STATE_INIT 'i' /* initializing (sublsn NULL) */ -#define SUBREL_STATE_DATASYNC 'd' /* data is being synchronized (sublsn NULL) */ -#define SUBREL_STATE_SYNCDONE 's' /* synchronization finished in front of apply (sublsn set) */ +#define SUBREL_STATE_DATASYNC 'd' /* data is being synchronized (sublsn + * NULL) */ +#define SUBREL_STATE_SYNCDONE 's' /* synchronization finished in front + * of apply (sublsn set) */ #define SUBREL_STATE_READY 'r' /* ready (sublsn set) */ /* These are never stored in the catalog, we only use them for IPC. */ @@ -69,9 +71,9 @@ typedef struct SubscriptionRelState } SubscriptionRelState; extern Oid SetSubscriptionRelState(Oid subid, Oid relid, char state, - XLogRecPtr sublsn); + XLogRecPtr sublsn); extern char GetSubscriptionRelState(Oid subid, Oid relid, - XLogRecPtr *sublsn, bool missing_ok); + XLogRecPtr *sublsn, bool missing_ok); extern void RemoveSubscriptionRel(Oid subid, Oid relid); extern List *GetSubscriptionRelations(Oid subid); diff --git a/src/include/commands/createas.h b/src/include/commands/createas.h index 0fb9990e043..c3c43f6b36f 100644 --- a/src/include/commands/createas.h +++ b/src/include/commands/createas.h @@ -22,7 +22,7 @@ extern ObjectAddress ExecCreateTableAs(CreateTableAsStmt *stmt, const char *queryString, - ParamListInfo params, QueryEnvironment *queryEnv, char *completionTag); + ParamListInfo params, QueryEnvironment *queryEnv, char *completionTag); extern int GetIntoRelEFlags(IntoClause *intoClause); diff --git a/src/include/commands/explain.h b/src/include/commands/explain.h index b77f81db97e..e2a0ee0d8cb 100644 --- a/src/include/commands/explain.h +++ b/src/include/commands/explain.h @@ -62,7 +62,7 @@ extern PGDLLIMPORT explain_get_index_name_hook_type explain_get_index_name_hook; extern void ExplainQuery(ParseState *pstate, ExplainStmt *stmt, const char *queryString, - ParamListInfo params, QueryEnvironment *queryEnv, DestReceiver *dest); + ParamListInfo params, QueryEnvironment *queryEnv, DestReceiver *dest); extern ExplainState *NewExplainState(void); diff --git a/src/include/commands/subscriptioncmds.h b/src/include/commands/subscriptioncmds.h index 17658793331..1e4428e6175 100644 --- a/src/include/commands/subscriptioncmds.h +++ b/src/include/commands/subscriptioncmds.h @@ -19,7 +19,7 @@ #include "nodes/parsenodes.h" extern ObjectAddress CreateSubscription(CreateSubscriptionStmt *stmt, - bool isTopLevel); + bool isTopLevel); extern ObjectAddress AlterSubscription(AlterSubscriptionStmt *stmt); extern void DropSubscription(DropSubscriptionStmt *stmt, bool isTopLevel); diff --git a/src/include/common/file_utils.h b/src/include/common/file_utils.h index 48cc97a4096..95c001905df 100644 --- a/src/include/common/file_utils.h +++ b/src/include/common/file_utils.h @@ -16,12 +16,12 @@ #define FILE_UTILS_H extern int fsync_fname(const char *fname, bool isdir, - const char *progname); + const char *progname); extern void fsync_pgdata(const char *pg_data, const char *progname, - int serverVersion); + int serverVersion); extern void fsync_dir_recurse(const char *dir, const char *progname); extern int durable_rename(const char *oldfile, const char *newfile, - const char *progname); -extern int fsync_parent_path(const char *fname, const char *progname); + const char *progname); +extern int fsync_parent_path(const char *fname, const char *progname); #endif /* FILE_UTILS_H */ diff --git a/src/include/common/scram-common.h b/src/include/common/scram-common.h index b5d107494c5..2ee51fbaec0 100644 --- a/src/include/common/scram-common.h +++ b/src/include/common/scram-common.h @@ -48,7 +48,7 @@ extern void scram_HMAC_update(scram_HMAC_ctx *ctx, const char *str, int slen); extern void scram_HMAC_final(uint8 *result, scram_HMAC_ctx *ctx); extern void scram_SaltedPassword(const char *password, const char *salt, - int saltlen, int iterations, uint8 *result); + int saltlen, int iterations, uint8 *result); extern void scram_H(const uint8 *str, int len, uint8 *result); extern void scram_ClientKey(const uint8 *salted_password, uint8 *result); extern void scram_ServerKey(const uint8 *salted_password, uint8 *result); diff --git a/src/include/executor/executor.h b/src/include/executor/executor.h index ab61d35a863..8cc5f3a413f 100644 --- a/src/include/executor/executor.h +++ b/src/include/executor/executor.h @@ -170,7 +170,7 @@ extern void standard_ExecutorStart(QueryDesc *queryDesc, int eflags); extern void ExecutorRun(QueryDesc *queryDesc, ScanDirection direction, uint64 count, bool execute_once); extern void standard_ExecutorRun(QueryDesc *queryDesc, - ScanDirection direction, uint64 count, bool execute_once); + ScanDirection direction, uint64 count, bool execute_once); extern void ExecutorFinish(QueryDesc *queryDesc); extern void standard_ExecutorFinish(QueryDesc *queryDesc); extern void ExecutorEnd(QueryDesc *queryDesc); @@ -536,6 +536,6 @@ extern void ExecSimpleRelationDelete(EState *estate, EPQState *epqstate, extern void CheckCmdReplicaIdentity(Relation rel, CmdType cmd); extern void CheckSubscriptionRelkind(char relkind, const char *nspname, - const char *relname); + const char *relname); #endif /* EXECUTOR_H */ diff --git a/src/include/executor/nodeGatherMerge.h b/src/include/executor/nodeGatherMerge.h index 3c8b42b6e5c..f5ba353762a 100644 --- a/src/include/executor/nodeGatherMerge.h +++ b/src/include/executor/nodeGatherMerge.h @@ -16,12 +16,12 @@ #include "nodes/execnodes.h" -extern GatherMergeState *ExecInitGatherMerge(GatherMerge * node, +extern GatherMergeState *ExecInitGatherMerge(GatherMerge *node, EState *estate, int eflags); -extern TupleTableSlot *ExecGatherMerge(GatherMergeState * node); -extern void ExecEndGatherMerge(GatherMergeState * node); -extern void ExecReScanGatherMerge(GatherMergeState * node); -extern void ExecShutdownGatherMerge(GatherMergeState * node); +extern TupleTableSlot *ExecGatherMerge(GatherMergeState *node); +extern void ExecEndGatherMerge(GatherMergeState *node); +extern void ExecReScanGatherMerge(GatherMergeState *node); +extern void ExecShutdownGatherMerge(GatherMergeState *node); #endif /* NODEGATHERMERGE_H */ diff --git a/src/include/executor/spi.h b/src/include/executor/spi.h index 94a805d4778..ffb4c28ad1a 100644 --- a/src/include/executor/spi.h +++ b/src/include/executor/spi.h @@ -44,8 +44,8 @@ typedef struct _SPI_plan *SPIPlanPtr; #define SPI_ERROR_NOATTRIBUTE (-9) #define SPI_ERROR_NOOUTFUNC (-10) #define SPI_ERROR_TYPUNKNOWN (-11) -#define SPI_ERROR_REL_DUPLICATE (-12) -#define SPI_ERROR_REL_NOT_FOUND (-13) +#define SPI_ERROR_REL_DUPLICATE (-12) +#define SPI_ERROR_REL_NOT_FOUND (-13) #define SPI_OK_CONNECT 1 #define SPI_OK_FINISH 2 @@ -152,9 +152,9 @@ extern void SPI_scroll_cursor_fetch(Portal, FetchDirection direction, long count extern void SPI_scroll_cursor_move(Portal, FetchDirection direction, long count); extern void SPI_cursor_close(Portal portal); -extern int SPI_register_relation(EphemeralNamedRelation enr); -extern int SPI_unregister_relation(const char *name); -extern int SPI_register_trigger_data(TriggerData *tdata); +extern int SPI_register_relation(EphemeralNamedRelation enr); +extern int SPI_unregister_relation(const char *name); +extern int SPI_register_trigger_data(TriggerData *tdata); extern void AtEOXact_SPI(bool isCommit); extern void AtEOSubXact_SPI(bool isCommit, SubTransactionId mySubid); diff --git a/src/include/executor/tablefunc.h b/src/include/executor/tablefunc.h index 89d6381220e..22ca916eb28 100644 --- a/src/include/executor/tablefunc.h +++ b/src/include/executor/tablefunc.h @@ -57,10 +57,10 @@ typedef struct TableFuncRoutine char *uri); void (*SetRowFilter) (struct TableFuncScanState *state, char *path); void (*SetColumnFilter) (struct TableFuncScanState *state, - char *path, int colnum); + char *path, int colnum); bool (*FetchRow) (struct TableFuncScanState *state); Datum (*GetValue) (struct TableFuncScanState *state, int colnum, - Oid typid, int32 typmod, bool *isnull); + Oid typid, int32 typmod, bool *isnull); void (*DestroyOpaque) (struct TableFuncScanState *state); } TableFuncRoutine; diff --git a/src/include/lib/simplehash.h b/src/include/lib/simplehash.h index 6c6c3ee0d09..a35addf636d 100644 --- a/src/include/lib/simplehash.h +++ b/src/include/lib/simplehash.h @@ -23,8 +23,8 @@ * - SH_DEFINE - if defined function definitions are generated * - SH_SCOPE - in which scope (e.g. extern, static inline) do function * declarations reside - * - SH_USE_NONDEFAULT_ALLOCATOR - if defined no element allocator functions - * are defined, so you can supply your own + * - SH_USE_NONDEFAULT_ALLOCATOR - if defined no element allocator functions + * are defined, so you can supply your own * The following parameters are only relevant when SH_DEFINE is defined: * - SH_KEY - name of the element in SH_ELEMENT_TYPE containing the hash key * - SH_EQUAL(table, a, b) - compare two table keys @@ -121,7 +121,7 @@ typedef struct SH_TYPE /* user defined data, useful for callbacks */ void *private_data; -} SH_TYPE; +} SH_TYPE; typedef enum SH_STATUS { @@ -134,20 +134,20 @@ typedef struct SH_ITERATOR uint32 cur; /* current element */ uint32 end; bool done; /* iterator exhausted? */ -} SH_ITERATOR; +} SH_ITERATOR; /* externally visible function prototypes */ SH_SCOPE SH_TYPE *SH_CREATE(MemoryContext ctx, uint32 nelements, - void *private_data); -SH_SCOPE void SH_DESTROY(SH_TYPE *tb); -SH_SCOPE void SH_GROW(SH_TYPE *tb, uint32 newsize); -SH_SCOPE SH_ELEMENT_TYPE *SH_INSERT(SH_TYPE *tb, SH_KEY_TYPE key, bool *found); -SH_SCOPE SH_ELEMENT_TYPE *SH_LOOKUP(SH_TYPE *tb, SH_KEY_TYPE key); -SH_SCOPE bool SH_DELETE(SH_TYPE *tb, SH_KEY_TYPE key); -SH_SCOPE void SH_START_ITERATE(SH_TYPE *tb, SH_ITERATOR *iter); -SH_SCOPE void SH_START_ITERATE_AT(SH_TYPE *tb, SH_ITERATOR *iter, uint32 at); -SH_SCOPE SH_ELEMENT_TYPE *SH_ITERATE(SH_TYPE *tb, SH_ITERATOR *iter); -SH_SCOPE void SH_STAT(SH_TYPE *tb); + void *private_data); +SH_SCOPE void SH_DESTROY(SH_TYPE * tb); +SH_SCOPE void SH_GROW(SH_TYPE * tb, uint32 newsize); +SH_SCOPE SH_ELEMENT_TYPE *SH_INSERT(SH_TYPE * tb, SH_KEY_TYPE key, bool *found); +SH_SCOPE SH_ELEMENT_TYPE *SH_LOOKUP(SH_TYPE * tb, SH_KEY_TYPE key); +SH_SCOPE bool SH_DELETE(SH_TYPE * tb, SH_KEY_TYPE key); +SH_SCOPE void SH_START_ITERATE(SH_TYPE * tb, SH_ITERATOR * iter); +SH_SCOPE void SH_START_ITERATE_AT(SH_TYPE * tb, SH_ITERATOR * iter, uint32 at); +SH_SCOPE SH_ELEMENT_TYPE *SH_ITERATE(SH_TYPE * tb, SH_ITERATOR * iter); +SH_SCOPE void SH_STAT(SH_TYPE * tb); #endif /* SH_DECLARE */ @@ -207,7 +207,7 @@ sh_pow2(uint64 num) * the hashtable. */ static inline void -SH_COMPUTE_PARAMETERS(SH_TYPE *tb, uint32 newsize) +SH_COMPUTE_PARAMETERS(SH_TYPE * tb, uint32 newsize) { uint64 size; @@ -245,14 +245,14 @@ SH_COMPUTE_PARAMETERS(SH_TYPE *tb, uint32 newsize) /* return the optimal bucket for the hash */ static inline uint32 -SH_INITIAL_BUCKET(SH_TYPE *tb, uint32 hash) +SH_INITIAL_BUCKET(SH_TYPE * tb, uint32 hash) { return hash & tb->sizemask; } /* return next bucket after the current, handling wraparound */ static inline uint32 -SH_NEXT(SH_TYPE *tb, uint32 curelem, uint32 startelem) +SH_NEXT(SH_TYPE * tb, uint32 curelem, uint32 startelem) { curelem = (curelem + 1) & tb->sizemask; @@ -263,7 +263,7 @@ SH_NEXT(SH_TYPE *tb, uint32 curelem, uint32 startelem) /* return bucket before the current, handling wraparound */ static inline uint32 -SH_PREV(SH_TYPE *tb, uint32 curelem, uint32 startelem) +SH_PREV(SH_TYPE * tb, uint32 curelem, uint32 startelem) { curelem = (curelem - 1) & tb->sizemask; @@ -274,7 +274,7 @@ SH_PREV(SH_TYPE *tb, uint32 curelem, uint32 startelem) /* return distance between bucket and its optimal position */ static inline uint32 -SH_DISTANCE_FROM_OPTIMAL(SH_TYPE *tb, uint32 optimal, uint32 bucket) +SH_DISTANCE_FROM_OPTIMAL(SH_TYPE * tb, uint32 optimal, uint32 bucket) { if (optimal <= bucket) return bucket - optimal; @@ -283,7 +283,7 @@ SH_DISTANCE_FROM_OPTIMAL(SH_TYPE *tb, uint32 optimal, uint32 bucket) } static inline uint32 -SH_ENTRY_HASH(SH_TYPE *tb, SH_ELEMENT_TYPE * entry) +SH_ENTRY_HASH(SH_TYPE * tb, SH_ELEMENT_TYPE * entry) { #ifdef SH_STORE_HASH return SH_GET_HASH(tb, entry); @@ -293,14 +293,14 @@ SH_ENTRY_HASH(SH_TYPE *tb, SH_ELEMENT_TYPE * entry) } /* default memory allocator function */ -static inline void *SH_ALLOCATE(SH_TYPE *type, Size size); -static inline void SH_FREE(SH_TYPE *type, void *pointer); +static inline void *SH_ALLOCATE(SH_TYPE * type, Size size); +static inline void SH_FREE(SH_TYPE * type, void *pointer); #ifndef SH_USE_NONDEFAULT_ALLOCATOR /* default memory allocator function */ static inline void * -SH_ALLOCATE(SH_TYPE *type, Size size) +SH_ALLOCATE(SH_TYPE * type, Size size) { return MemoryContextAllocExtended(type->ctx, size, MCXT_ALLOC_HUGE | MCXT_ALLOC_ZERO); @@ -308,7 +308,7 @@ SH_ALLOCATE(SH_TYPE *type, Size size) /* default memory free function */ static inline void -SH_FREE(SH_TYPE *type, void *pointer) +SH_FREE(SH_TYPE * type, void *pointer) { pfree(pointer); } @@ -346,7 +346,7 @@ SH_CREATE(MemoryContext ctx, uint32 nelements, void *private_data) /* destroy a previously created hash table */ SH_SCOPE void -SH_DESTROY(SH_TYPE *tb) +SH_DESTROY(SH_TYPE * tb) { SH_FREE(tb, tb->data); pfree(tb); @@ -360,7 +360,7 @@ SH_DESTROY(SH_TYPE *tb) * performance-wise, when known at some point. */ SH_SCOPE void -SH_GROW(SH_TYPE *tb, uint32 newsize) +SH_GROW(SH_TYPE * tb, uint32 newsize) { uint64 oldsize = tb->size; SH_ELEMENT_TYPE *olddata = tb->data; @@ -471,7 +471,7 @@ SH_GROW(SH_TYPE *tb, uint32 newsize) * case. */ SH_SCOPE SH_ELEMENT_TYPE * -SH_INSERT(SH_TYPE *tb, SH_KEY_TYPE key, bool *found) +SH_INSERT(SH_TYPE * tb, SH_KEY_TYPE key, bool *found) { uint32 hash = SH_HASH_KEY(tb, key); uint32 startelem; @@ -635,7 +635,7 @@ restart: * Lookup up entry in hash table. Returns NULL if key not present. */ SH_SCOPE SH_ELEMENT_TYPE * -SH_LOOKUP(SH_TYPE *tb, SH_KEY_TYPE key) +SH_LOOKUP(SH_TYPE * tb, SH_KEY_TYPE key) { uint32 hash = SH_HASH_KEY(tb, key); const uint32 startelem = SH_INITIAL_BUCKET(tb, hash); @@ -671,7 +671,7 @@ SH_LOOKUP(SH_TYPE *tb, SH_KEY_TYPE key) * present. */ SH_SCOPE bool -SH_DELETE(SH_TYPE *tb, SH_KEY_TYPE key) +SH_DELETE(SH_TYPE * tb, SH_KEY_TYPE key) { uint32 hash = SH_HASH_KEY(tb, key); uint32 startelem = SH_INITIAL_BUCKET(tb, hash); @@ -742,7 +742,7 @@ SH_DELETE(SH_TYPE *tb, SH_KEY_TYPE key) * Initialize iterator. */ SH_SCOPE void -SH_START_ITERATE(SH_TYPE *tb, SH_ITERATOR *iter) +SH_START_ITERATE(SH_TYPE * tb, SH_ITERATOR * iter) { int i; uint64 startelem = PG_UINT64_MAX; @@ -782,7 +782,7 @@ SH_START_ITERATE(SH_TYPE *tb, SH_ITERATOR *iter) * same position. */ SH_SCOPE void -SH_START_ITERATE_AT(SH_TYPE *tb, SH_ITERATOR *iter, uint32 at) +SH_START_ITERATE_AT(SH_TYPE * tb, SH_ITERATOR * iter, uint32 at) { /* * Iterate backwards, that allows the current element to be deleted, even @@ -804,7 +804,7 @@ SH_START_ITERATE_AT(SH_TYPE *tb, SH_ITERATOR *iter, uint32 at) * visited at least once, nor a guarantee that a node is visited at most once. */ SH_SCOPE SH_ELEMENT_TYPE * -SH_ITERATE(SH_TYPE *tb, SH_ITERATOR *iter) +SH_ITERATE(SH_TYPE * tb, SH_ITERATOR * iter) { while (!iter->done) { @@ -831,7 +831,7 @@ SH_ITERATE(SH_TYPE *tb, SH_ITERATOR *iter) * debugging/profiling purposes only. */ SH_SCOPE void -SH_STAT(SH_TYPE *tb) +SH_STAT(SH_TYPE * tb) { uint32 max_chain_length = 0; uint32 total_chain_length = 0; diff --git a/src/include/libpq/hba.h b/src/include/libpq/hba.h index 9a4f228d6a7..f28b860877c 100644 --- a/src/include/libpq/hba.h +++ b/src/include/libpq/hba.h @@ -90,13 +90,13 @@ typedef struct HbaLine bool compat_realm; bool upn_username; List *radiusservers; - char *radiusservers_s; + char *radiusservers_s; List *radiussecrets; - char *radiussecrets_s; + char *radiussecrets_s; List *radiusidentifiers; - char *radiusidentifiers_s; + char *radiusidentifiers_s; List *radiusports; - char *radiusports_s; + char *radiusports_s; } HbaLine; typedef struct IdentLine diff --git a/src/include/mb/pg_wchar.h b/src/include/mb/pg_wchar.h index 9c5e749c9e7..737ab1c7133 100644 --- a/src/include/mb/pg_wchar.h +++ b/src/include/mb/pg_wchar.h @@ -382,8 +382,8 @@ extern const pg_wchar_tbl pg_wchar_table[]; * * 1. Using a radix tree, from source to destination code. * 2. Using a sorted array of source -> destination code pairs. This - * method is used for "combining" characters. There are so few of - * them that building a radix tree would be wasteful. + * method is used for "combining" characters. There are so few of + * them that building a radix tree would be wasteful. * 3. Using a conversion function. */ @@ -421,35 +421,35 @@ typedef struct const uint32 *chars32; /* Radix tree for 1-byte inputs */ - uint32 b1root; /* offset of table in the chars[16|32] array */ - uint8 b1_lower; /* min allowed value for a single byte input */ - uint8 b1_upper; /* max allowed value for a single byte input */ + uint32 b1root; /* offset of table in the chars[16|32] array */ + uint8 b1_lower; /* min allowed value for a single byte input */ + uint8 b1_upper; /* max allowed value for a single byte input */ /* Radix tree for 2-byte inputs */ - uint32 b2root; /* offset of 1st byte's table */ - uint8 b2_1_lower; /* min/max allowed value for 1st input byte */ + uint32 b2root; /* offset of 1st byte's table */ + uint8 b2_1_lower; /* min/max allowed value for 1st input byte */ uint8 b2_1_upper; - uint8 b2_2_lower; /* min/max allowed value for 2nd input byte */ + uint8 b2_2_lower; /* min/max allowed value for 2nd input byte */ uint8 b2_2_upper; /* Radix tree for 3-byte inputs */ - uint32 b3root; /* offset of 1st byte's table */ - uint8 b3_1_lower; /* min/max allowed value for 1st input byte */ + uint32 b3root; /* offset of 1st byte's table */ + uint8 b3_1_lower; /* min/max allowed value for 1st input byte */ uint8 b3_1_upper; - uint8 b3_2_lower; /* min/max allowed value for 2nd input byte */ + uint8 b3_2_lower; /* min/max allowed value for 2nd input byte */ uint8 b3_2_upper; - uint8 b3_3_lower; /* min/max allowed value for 3rd input byte */ + uint8 b3_3_lower; /* min/max allowed value for 3rd input byte */ uint8 b3_3_upper; /* Radix tree for 4-byte inputs */ - uint32 b4root; /* offset of 1st byte's table */ - uint8 b4_1_lower; /* min/max allowed value for 1st input byte */ + uint32 b4root; /* offset of 1st byte's table */ + uint8 b4_1_lower; /* min/max allowed value for 1st input byte */ uint8 b4_1_upper; - uint8 b4_2_lower; /* min/max allowed value for 2nd input byte */ + uint8 b4_2_lower; /* min/max allowed value for 2nd input byte */ uint8 b4_2_upper; - uint8 b4_3_lower; /* min/max allowed value for 3rd input byte */ + uint8 b4_3_lower; /* min/max allowed value for 3rd input byte */ uint8 b4_3_upper; - uint8 b4_4_lower; /* min/max allowed value for 4th input byte */ + uint8 b4_4_lower; /* min/max allowed value for 4th input byte */ uint8 b4_4_upper; } pg_mb_radix_tree; diff --git a/src/include/nodes/execnodes.h b/src/include/nodes/execnodes.h index f289f3c3c25..d33392f3b55 100644 --- a/src/include/nodes/execnodes.h +++ b/src/include/nodes/execnodes.h @@ -442,7 +442,7 @@ typedef struct EState ParamListInfo es_param_list_info; /* values of external params */ ParamExecData *es_param_exec_vals; /* values of internal params */ - QueryEnvironment *es_queryEnv; /* query environment */ + QueryEnvironment *es_queryEnv; /* query environment */ /* Other working state: */ MemoryContext es_query_cxt; /* per-query context in which EState lives */ @@ -485,7 +485,7 @@ typedef struct EState bool *es_epqScanDone; /* true if EPQ tuple has been fetched */ /* The per-query shared memory area to use for parallel execution. */ - struct dsa_area *es_query_dsa; + struct dsa_area *es_query_dsa; } EState; @@ -938,14 +938,13 @@ typedef struct ModifyTableState TupleTableSlot *mt_conflproj; /* CONFLICT ... SET ... projection * target */ struct PartitionDispatchData **mt_partition_dispatch_info; - /* Tuple-routing support info */ - int mt_num_dispatch; /* Number of entries in the above - * array */ - int mt_num_partitions; /* Number of members in the - * following arrays */ - ResultRelInfo *mt_partitions; /* Per partition result relation */ + /* Tuple-routing support info */ + int mt_num_dispatch; /* Number of entries in the above array */ + int mt_num_partitions; /* Number of members in the following + * arrays */ + ResultRelInfo *mt_partitions; /* Per partition result relation */ TupleConversionMap **mt_partition_tupconv_maps; - /* Per partition tuple conversion map */ + /* Per partition tuple conversion map */ TupleTableSlot *mt_partition_tuple_slot; } ModifyTableState; diff --git a/src/include/nodes/makefuncs.h b/src/include/nodes/makefuncs.h index 1f4bad7df6f..53ea6598c8a 100644 --- a/src/include/nodes/makefuncs.h +++ b/src/include/nodes/makefuncs.h @@ -82,7 +82,7 @@ extern FuncCall *makeFuncCall(List *name, List *args, int location); extern DefElem *makeDefElem(char *name, Node *arg, int location); extern DefElem *makeDefElemExtended(char *nameSpace, char *name, Node *arg, - DefElemAction defaction, int location); + DefElemAction defaction, int location); extern GroupingSet *makeGroupingSet(GroupingSetKind kind, List *content, int location); diff --git a/src/include/nodes/parsenodes.h b/src/include/nodes/parsenodes.h index d396be382b5..4b8727e9193 100644 --- a/src/include/nodes/parsenodes.h +++ b/src/include/nodes/parsenodes.h @@ -643,7 +643,7 @@ typedef struct ColumnDef bool is_local; /* column has local (non-inherited) def'n */ bool is_not_null; /* NOT NULL constraint specified? */ bool is_from_type; /* column definition came from table type */ - bool is_from_parent; /* column def came from partition parent */ + bool is_from_parent; /* column def came from partition parent */ char storage; /* attstorage setting, or 0 for default */ Node *raw_default; /* default value (untransformed parse tree) */ Node *cooked_default; /* default value (transformed expr tree) */ @@ -1824,8 +1824,8 @@ typedef struct GrantStmt bool is_grant; /* true = GRANT, false = REVOKE */ GrantTargetType targtype; /* type of the grant target */ GrantObjectType objtype; /* kind of object being operated on */ - List *objects; /* list of RangeVar nodes, ObjectWithArgs nodes, - * or plain names (as Value strings) */ + List *objects; /* list of RangeVar nodes, ObjectWithArgs + * nodes, or plain names (as Value strings) */ List *privileges; /* list of AccessPriv nodes */ /* privileges == NIL denotes ALL PRIVILEGES */ List *grantees; /* list of RoleSpec nodes */ @@ -1843,9 +1843,9 @@ typedef struct ObjectWithArgs NodeTag type; List *objname; /* qualified name of function/operator */ List *objargs; /* list of Typename nodes */ - bool args_unspecified; /* argument list was omitted, so name must - * be unique (note that objargs == NIL means - * zero args) */ + bool args_unspecified; /* argument list was omitted, so name + * must be unique (note that objargs + * == NIL means zero args) */ } ObjectWithArgs; /* @@ -3343,7 +3343,7 @@ typedef struct CreatePublicationStmt char *pubname; /* Name of of the publication */ List *options; /* List of DefElem nodes */ List *tables; /* Optional list of tables to add */ - bool for_all_tables; /* Special publication for all tables in db */ + bool for_all_tables; /* Special publication for all tables in db */ } CreatePublicationStmt; typedef struct AlterPublicationStmt @@ -3356,8 +3356,8 @@ typedef struct AlterPublicationStmt /* parameters used for ALTER PUBLICATION ... ADD/DROP TABLE */ List *tables; /* List of tables to add/drop */ - bool for_all_tables; /* Special publication for all tables in db */ - DefElemAction tableAction; /* What action to perform with the tables */ + bool for_all_tables; /* Special publication for all tables in db */ + DefElemAction tableAction; /* What action to perform with the tables */ } AlterPublicationStmt; typedef struct CreateSubscriptionStmt @@ -3382,7 +3382,7 @@ typedef enum AlterSubscriptionType typedef struct AlterSubscriptionStmt { NodeTag type; - AlterSubscriptionType kind; /* ALTER_SUBSCRIPTION_OPTIONS, etc */ + AlterSubscriptionType kind; /* ALTER_SUBSCRIPTION_OPTIONS, etc */ char *subname; /* Name of of the subscription */ char *conninfo; /* Connection string to publisher */ List *publication; /* One or more publication to subscribe to */ diff --git a/src/include/nodes/plannodes.h b/src/include/nodes/plannodes.h index 0b08e49dd4b..d84372da386 100644 --- a/src/include/nodes/plannodes.h +++ b/src/include/nodes/plannodes.h @@ -66,8 +66,8 @@ typedef struct PlannedStmt List *resultRelations; /* integer list of RT indexes, or NIL */ /* - * rtable indexes of non-leaf target relations for UPDATE/DELETE on - * all the partitioned table mentioned in the query. + * rtable indexes of non-leaf target relations for UPDATE/DELETE on all + * the partitioned table mentioned in the query. */ List *nonleafResultRelations; @@ -221,7 +221,7 @@ typedef struct ModifyTable List *partitioned_rels; List *resultRelations; /* integer list of RT indexes */ int resultRelIndex; /* index of first resultRel in plan's list */ - int rootResultRelIndex; /* index of the partitioned table root */ + int rootResultRelIndex; /* index of the partitioned table root */ List *plans; /* plan(s) producing source data */ List *withCheckOptionLists; /* per-target-table WCO lists */ List *returningLists; /* per-target-table RETURNING tlists */ diff --git a/src/include/nodes/relation.h b/src/include/nodes/relation.h index adbd3dd5566..902e9faf12a 100644 --- a/src/include/nodes/relation.h +++ b/src/include/nodes/relation.h @@ -107,8 +107,8 @@ typedef struct PlannerGlobal List *resultRelations; /* "flat" list of integer RT indexes */ - List *nonleafResultRelations; /* "flat" list of integer RT indexes */ - List *rootResultRelations; /* "flat" list of integer RT indexes */ + List *nonleafResultRelations; /* "flat" list of integer RT indexes */ + List *rootResultRelations; /* "flat" list of integer RT indexes */ List *relationOids; /* OIDs of relations the plan depends on */ diff --git a/src/include/optimizer/cost.h b/src/include/optimizer/cost.h index ed70defa179..3cf681e91b1 100644 --- a/src/include/optimizer/cost.h +++ b/src/include/optimizer/cost.h @@ -99,7 +99,7 @@ extern void cost_tablefuncscan(Path *path, PlannerInfo *root, extern void cost_ctescan(Path *path, PlannerInfo *root, RelOptInfo *baserel, ParamPathInfo *param_info); extern void cost_namedtuplestorescan(Path *path, PlannerInfo *root, - RelOptInfo *baserel, ParamPathInfo *param_info); + RelOptInfo *baserel, ParamPathInfo *param_info); extern void cost_recursive_union(Path *runion, Path *nrterm, Path *rterm); extern void cost_sort(Path *path, PlannerInfo *root, List *pathkeys, Cost input_cost, double tuples, int width, @@ -189,7 +189,7 @@ extern void set_namedtuplestore_size_estimates(PlannerInfo *root, RelOptInfo *re extern void set_foreign_size_estimates(PlannerInfo *root, RelOptInfo *rel); extern PathTarget *set_pathtarget_cost_width(PlannerInfo *root, PathTarget *target); extern double compute_bitmap_pages(PlannerInfo *root, RelOptInfo *baserel, - Path *bitmapqual, int loop_count, Cost *cost, double *tuple); + Path *bitmapqual, int loop_count, Cost *cost, double *tuple); /* * prototypes for clausesel.c @@ -206,8 +206,8 @@ extern Selectivity clause_selectivity(PlannerInfo *root, JoinType jointype, SpecialJoinInfo *sjinfo); extern void cost_gather_merge(GatherMergePath *path, PlannerInfo *root, - RelOptInfo *rel, ParamPathInfo *param_info, - Cost input_startup_cost, Cost input_total_cost, - double *rows); + RelOptInfo *rel, ParamPathInfo *param_info, + Cost input_startup_cost, Cost input_total_cost, + double *rows); #endif /* COST_H */ diff --git a/src/include/optimizer/pathnode.h b/src/include/optimizer/pathnode.h index 77bc7704acb..245825c38b9 100644 --- a/src/include/optimizer/pathnode.h +++ b/src/include/optimizer/pathnode.h @@ -81,12 +81,12 @@ extern GatherPath *create_gather_path(PlannerInfo *root, RelOptInfo *rel, Path *subpath, PathTarget *target, Relids required_outer, double *rows); extern GatherMergePath *create_gather_merge_path(PlannerInfo *root, - RelOptInfo *rel, - Path *subpath, - PathTarget *target, - List *pathkeys, - Relids required_outer, - double *rows); + RelOptInfo *rel, + Path *subpath, + PathTarget *target, + List *pathkeys, + Relids required_outer, + double *rows); extern SubqueryScanPath *create_subqueryscan_path(PlannerInfo *root, RelOptInfo *rel, Path *subpath, List *pathkeys, Relids required_outer); @@ -101,7 +101,7 @@ extern Path *create_tablefuncscan_path(PlannerInfo *root, RelOptInfo *rel, extern Path *create_ctescan_path(PlannerInfo *root, RelOptInfo *rel, Relids required_outer); extern Path *create_namedtuplestorescan_path(PlannerInfo *root, RelOptInfo *rel, - Relids required_outer); + Relids required_outer); extern Path *create_worktablescan_path(PlannerInfo *root, RelOptInfo *rel, Relids required_outer); extern ForeignPath *create_foreignscan_path(PlannerInfo *root, RelOptInfo *rel, diff --git a/src/include/optimizer/paths.h b/src/include/optimizer/paths.h index 25fe78cddd4..a216f9e9127 100644 --- a/src/include/optimizer/paths.h +++ b/src/include/optimizer/paths.h @@ -57,7 +57,7 @@ extern void generate_gather_paths(PlannerInfo *root, RelOptInfo *rel); extern int compute_parallel_worker(RelOptInfo *rel, double heap_pages, double index_pages); extern void create_partial_bitmap_paths(PlannerInfo *root, RelOptInfo *rel, - Path *bitmapqual); + Path *bitmapqual); #ifdef OPTIMIZER_DEBUG extern void debug_print_rel(PlannerInfo *root, RelOptInfo *rel); diff --git a/src/include/parser/parse_func.h b/src/include/parser/parse_func.h index 8ccf7a95383..5be1812242a 100644 --- a/src/include/parser/parse_func.h +++ b/src/include/parser/parse_func.h @@ -63,9 +63,9 @@ extern const char *func_signature_string(List *funcname, int nargs, extern Oid LookupFuncName(List *funcname, int nargs, const Oid *argtypes, bool noError); extern Oid LookupFuncWithArgs(ObjectWithArgs *func, - bool noError); + bool noError); extern Oid LookupAggWithArgs(ObjectWithArgs *agg, - bool noError); + bool noError); extern void check_srf_call_placement(ParseState *pstate, int location); diff --git a/src/include/parser/parse_node.h b/src/include/parser/parse_node.h index 1035bad322c..0b54840e295 100644 --- a/src/include/parser/parse_node.h +++ b/src/include/parser/parse_node.h @@ -189,7 +189,8 @@ struct ParseState bool p_resolve_unknowns; /* resolve unknown-type SELECT outputs * as type text */ - QueryEnvironment *p_queryEnv; /* curr env, incl refs to enclosing env */ + QueryEnvironment *p_queryEnv; /* curr env, incl refs to enclosing + * env */ /* Flags telling about things found in the query: */ bool p_hasAggs; diff --git a/src/include/parser/parse_oper.h b/src/include/parser/parse_oper.h index a8f75b5921e..d783b37f0f5 100644 --- a/src/include/parser/parse_oper.h +++ b/src/include/parser/parse_oper.h @@ -25,7 +25,7 @@ typedef HeapTuple Operator; extern Oid LookupOperName(ParseState *pstate, List *opername, Oid oprleft, Oid oprright, bool noError, int location); -extern Oid LookupOperWithArgs(ObjectWithArgs *oper, bool noError); +extern Oid LookupOperWithArgs(ObjectWithArgs *oper, bool noError); /* Routines to find operators matching a name and given input types */ /* NB: the selected operator may require coercion of the input types! */ diff --git a/src/include/replication/logical.h b/src/include/replication/logical.h index 090f9c82680..159da7f23f9 100644 --- a/src/include/replication/logical.h +++ b/src/include/replication/logical.h @@ -28,7 +28,7 @@ typedef LogicalOutputPluginWriterWrite LogicalOutputPluginWriterPrepareWrite; typedef void (*LogicalOutputPluginWriterUpdateProgress) ( struct LogicalDecodingContext *lr, - XLogRecPtr Ptr, + XLogRecPtr Ptr, TransactionId xid ); @@ -93,14 +93,14 @@ extern LogicalDecodingContext *CreateInitDecodingContext(char *plugin, XLogPageReadCB read_page, LogicalOutputPluginWriterPrepareWrite prepare_write, LogicalOutputPluginWriterWrite do_write, - LogicalOutputPluginWriterUpdateProgress update_progress); + LogicalOutputPluginWriterUpdateProgress update_progress); extern LogicalDecodingContext *CreateDecodingContext( XLogRecPtr start_lsn, List *output_plugin_options, XLogPageReadCB read_page, LogicalOutputPluginWriterPrepareWrite prepare_write, LogicalOutputPluginWriterWrite do_write, - LogicalOutputPluginWriterUpdateProgress update_progress); + LogicalOutputPluginWriterUpdateProgress update_progress); extern void DecodingContextFindStartpoint(LogicalDecodingContext *ctx); extern bool DecodingContextReady(LogicalDecodingContext *ctx); extern void FreeDecodingContext(LogicalDecodingContext *ctx); diff --git a/src/include/replication/logicallauncher.h b/src/include/replication/logicallauncher.h index fb3c2f53709..d202a237e7a 100644 --- a/src/include/replication/logicallauncher.h +++ b/src/include/replication/logicallauncher.h @@ -12,8 +12,8 @@ #ifndef LOGICALLAUNCHER_H #define LOGICALLAUNCHER_H -extern int max_logical_replication_workers; -extern int max_sync_workers_per_subscription; +extern int max_logical_replication_workers; +extern int max_sync_workers_per_subscription; extern void ApplyLauncherRegister(void); extern void ApplyLauncherMain(Datum main_arg); diff --git a/src/include/replication/logicalproto.h b/src/include/replication/logicalproto.h index 9d0c15d4036..e7679e29edf 100644 --- a/src/include/replication/logicalproto.h +++ b/src/include/replication/logicalproto.h @@ -31,52 +31,52 @@ typedef struct LogicalRepTupleData { /* column values in text format, or NULL for a null value: */ - char *values[MaxTupleAttributeNumber]; + char *values[MaxTupleAttributeNumber]; /* markers for changed/unchanged column values: */ - bool changed[MaxTupleAttributeNumber]; + bool changed[MaxTupleAttributeNumber]; } LogicalRepTupleData; -typedef uint32 LogicalRepRelId; +typedef uint32 LogicalRepRelId; /* Relation information */ typedef struct LogicalRepRelation { /* Info coming from the remote side. */ - LogicalRepRelId remoteid; /* unique id of the relation */ - char *nspname; /* schema name */ - char *relname; /* relation name */ - int natts; /* number of columns */ - char **attnames; /* column names */ - Oid *atttyps; /* column types */ - char replident; /* replica identity */ - Bitmapset *attkeys; /* Bitmap of key columns */ + LogicalRepRelId remoteid; /* unique id of the relation */ + char *nspname; /* schema name */ + char *relname; /* relation name */ + int natts; /* number of columns */ + char **attnames; /* column names */ + Oid *atttyps; /* column types */ + char replident; /* replica identity */ + Bitmapset *attkeys; /* Bitmap of key columns */ } LogicalRepRelation; /* Type mapping info */ typedef struct LogicalRepTyp { - Oid remoteid; /* unique id of the type */ - char *nspname; /* schema name */ - char *typname; /* name of the type */ - Oid typoid; /* local type Oid */ + Oid remoteid; /* unique id of the type */ + char *nspname; /* schema name */ + char *typname; /* name of the type */ + Oid typoid; /* local type Oid */ } LogicalRepTyp; /* Transaction info */ typedef struct LogicalRepBeginData { - XLogRecPtr final_lsn; - TimestampTz committime; - TransactionId xid; + XLogRecPtr final_lsn; + TimestampTz committime; + TransactionId xid; } LogicalRepBeginData; typedef struct LogicalRepCommitData { - XLogRecPtr commit_lsn; - XLogRecPtr end_lsn; - TimestampTz committime; + XLogRecPtr commit_lsn; + XLogRecPtr end_lsn; + TimestampTz committime; } LogicalRepCommitData; -extern void logicalrep_write_begin(StringInfo out, ReorderBufferTXN *txn); +extern void logicalrep_write_begin(StringInfo out, ReorderBufferTXN *txn); extern void logicalrep_read_begin(StringInfo in, LogicalRepBeginData *begin_data); extern void logicalrep_write_commit(StringInfo out, ReorderBufferTXN *txn, @@ -87,20 +87,20 @@ extern void logicalrep_write_origin(StringInfo out, const char *origin, XLogRecPtr origin_lsn); extern char *logicalrep_read_origin(StringInfo in, XLogRecPtr *origin_lsn); extern void logicalrep_write_insert(StringInfo out, Relation rel, - HeapTuple newtuple); + HeapTuple newtuple); extern LogicalRepRelId logicalrep_read_insert(StringInfo in, LogicalRepTupleData *newtup); extern void logicalrep_write_update(StringInfo out, Relation rel, HeapTuple oldtuple, - HeapTuple newtuple); + HeapTuple newtuple); extern LogicalRepRelId logicalrep_read_update(StringInfo in, bool *has_oldtuple, LogicalRepTupleData *oldtup, LogicalRepTupleData *newtup); extern void logicalrep_write_delete(StringInfo out, Relation rel, - HeapTuple oldtuple); + HeapTuple oldtuple); extern LogicalRepRelId logicalrep_read_delete(StringInfo in, - LogicalRepTupleData *oldtup); + LogicalRepTupleData *oldtup); extern void logicalrep_write_rel(StringInfo out, Relation rel); extern LogicalRepRelation *logicalrep_read_rel(StringInfo in); extern void logicalrep_write_typ(StringInfo out, Oid typoid); extern void logicalrep_read_typ(StringInfo out, LogicalRepTyp *ltyp); -#endif /* LOGICALREP_PROTO_H */ +#endif /* LOGICALREP_PROTO_H */ diff --git a/src/include/replication/logicalrelation.h b/src/include/replication/logicalrelation.h index 7fb7fbfb4db..3b814d3b2b5 100644 --- a/src/include/replication/logicalrelation.h +++ b/src/include/replication/logicalrelation.h @@ -16,28 +16,27 @@ typedef struct LogicalRepRelMapEntry { - LogicalRepRelation remoterel; /* key is remoterel.remoteid */ + LogicalRepRelation remoterel; /* key is remoterel.remoteid */ /* Mapping to local relation, filled as needed. */ - Oid localreloid; /* local relation id */ - Relation localrel; /* relcache entry */ - AttrNumber *attrmap; /* map of local attributes to - * remote ones */ - bool updatable; /* Can apply updates/deletes? */ + Oid localreloid; /* local relation id */ + Relation localrel; /* relcache entry */ + AttrNumber *attrmap; /* map of local attributes to remote ones */ + bool updatable; /* Can apply updates/deletes? */ /* Sync state. */ - char state; - XLogRecPtr statelsn; + char state; + XLogRecPtr statelsn; } LogicalRepRelMapEntry; extern void logicalrep_relmap_update(LogicalRepRelation *remoterel); extern LogicalRepRelMapEntry *logicalrep_rel_open(LogicalRepRelId remoteid, - LOCKMODE lockmode); + LOCKMODE lockmode); extern void logicalrep_rel_close(LogicalRepRelMapEntry *rel, - LOCKMODE lockmode); + LOCKMODE lockmode); extern void logicalrep_typmap_update(LogicalRepTyp *remotetyp); -extern Oid logicalrep_typmap_getid(Oid remoteid); +extern Oid logicalrep_typmap_getid(Oid remoteid); #endif /* LOGICALRELATION_H */ diff --git a/src/include/replication/pgoutput.h b/src/include/replication/pgoutput.h index 83e395823e4..8cd29ab1641 100644 --- a/src/include/replication/pgoutput.h +++ b/src/include/replication/pgoutput.h @@ -17,14 +17,14 @@ typedef struct PGOutputData { - MemoryContext context; /* private memory context for transient - * allocations */ + MemoryContext context; /* private memory context for transient + * allocations */ /* client info */ - uint32 protocol_version; + uint32 protocol_version; - List *publication_names; - List *publications; + List *publication_names; + List *publications; } PGOutputData; -#endif /* PGOUTPUT_H */ +#endif /* PGOUTPUT_H */ diff --git a/src/include/replication/snapbuild.h b/src/include/replication/snapbuild.h index ccb5f831c44..dc676a0ce2e 100644 --- a/src/include/replication/snapbuild.h +++ b/src/include/replication/snapbuild.h @@ -33,8 +33,8 @@ typedef enum * that started after this. * * Once we reached this we start to collect changes. We cannot apply them - * yet, because they might be based on transactions that were still running - * when FULL_SNAPSHOT was reached. + * yet, because they might be based on transactions that were still + * running when FULL_SNAPSHOT was reached. */ SNAPBUILD_FULL_SNAPSHOT = 1, diff --git a/src/include/replication/syncrep.h b/src/include/replication/syncrep.h index 55b94f33926..1676ea09520 100644 --- a/src/include/replication/syncrep.h +++ b/src/include/replication/syncrep.h @@ -48,7 +48,7 @@ typedef struct SyncRepConfigData int config_size; /* total size of this struct, in bytes */ int num_sync; /* number of sync standbys that we need to * wait for */ - uint8 syncrep_method; /* method to choose sync standbys */ + uint8 syncrep_method; /* method to choose sync standbys */ int nmembers; /* number of members in the following list */ /* member_names contains nmembers consecutive nul-terminated C strings */ char member_names[FLEXIBLE_ARRAY_MEMBER]; diff --git a/src/include/replication/walreceiver.h b/src/include/replication/walreceiver.h index cc31bc6a34e..31d090c99d9 100644 --- a/src/include/replication/walreceiver.h +++ b/src/include/replication/walreceiver.h @@ -129,8 +129,8 @@ typedef struct * Latch used by startup process to wake up walreceiver after telling it * where to start streaming (after setting receiveStart and * receiveStartTLI), and also to tell it to send apply feedback to the - * primary whenever specially marked commit records are applied. - * This is normally mapped to procLatch when walreceiver is running. + * primary whenever specially marked commit records are applied. This is + * normally mapped to procLatch when walreceiver is running. */ Latch *latch; } WalRcvData; @@ -139,25 +139,23 @@ extern WalRcvData *WalRcv; typedef struct { - bool logical; /* True if this is logical - replication stream, false if - physical stream. */ - char *slotname; /* Name of the replication slot - or NULL. */ - XLogRecPtr startpoint; /* LSN of starting point. */ + bool logical; /* True if this is logical replication stream, + * false if physical stream. */ + char *slotname; /* Name of the replication slot or NULL. */ + XLogRecPtr startpoint; /* LSN of starting point. */ union { struct { - TimeLineID startpointTLI; /* Starting timeline */ - } physical; + TimeLineID startpointTLI; /* Starting timeline */ + } physical; struct { - uint32 proto_version; /* Logical protocol version */ - List *publication_names; /* String list of publications */ - } logical; - } proto; + uint32 proto_version; /* Logical protocol version */ + List *publication_names; /* String list of publications */ + } logical; + } proto; } WalRcvStreamOptions; struct WalReceiverConn; @@ -171,11 +169,13 @@ typedef struct WalReceiverConn WalReceiverConn; typedef enum { WALRCV_ERROR, /* There was error when executing the query. */ - WALRCV_OK_COMMAND, /* Query executed utility or replication command. */ + WALRCV_OK_COMMAND, /* Query executed utility or replication + * command. */ WALRCV_OK_TUPLES, /* Query returned tuples. */ WALRCV_OK_COPY_IN, /* Query started COPY FROM. */ WALRCV_OK_COPY_OUT, /* Query started COPY TO. */ - WALRCV_OK_COPY_BOTH /* Query started COPY BOTH replication protocol. */ + WALRCV_OK_COPY_BOTH /* Query started COPY BOTH replication + * protocol. */ } WalRcvExecStatus; /* @@ -184,57 +184,57 @@ typedef enum */ typedef struct WalRcvExecResult { - WalRcvExecStatus status; - char *err; - Tuplestorestate *tuplestore; - TupleDesc tupledesc; + WalRcvExecStatus status; + char *err; + Tuplestorestate *tuplestore; + TupleDesc tupledesc; } WalRcvExecResult; /* libpqwalreceiver hooks */ typedef WalReceiverConn *(*walrcv_connect_fn) (const char *conninfo, bool logical, - const char *appname, - char **err); + const char *appname, + char **err); typedef void (*walrcv_check_conninfo_fn) (const char *conninfo); typedef char *(*walrcv_get_conninfo_fn) (WalReceiverConn *conn); typedef char *(*walrcv_identify_system_fn) (WalReceiverConn *conn, - TimeLineID *primary_tli, - int *server_version); + TimeLineID *primary_tli, + int *server_version); typedef void (*walrcv_readtimelinehistoryfile_fn) (WalReceiverConn *conn, - TimeLineID tli, - char **filename, - char **content, int *size); + TimeLineID tli, + char **filename, + char **content, int *size); typedef bool (*walrcv_startstreaming_fn) (WalReceiverConn *conn, - const WalRcvStreamOptions *options); + const WalRcvStreamOptions *options); typedef void (*walrcv_endstreaming_fn) (WalReceiverConn *conn, - TimeLineID *next_tli); + TimeLineID *next_tli); typedef int (*walrcv_receive_fn) (WalReceiverConn *conn, char **buffer, - pgsocket *wait_fd); + pgsocket *wait_fd); typedef void (*walrcv_send_fn) (WalReceiverConn *conn, const char *buffer, - int nbytes); + int nbytes); typedef char *(*walrcv_create_slot_fn) (WalReceiverConn *conn, const char *slotname, bool temporary, - CRSSnapshotAction snapshot_action, - XLogRecPtr *lsn); + CRSSnapshotAction snapshot_action, + XLogRecPtr *lsn); typedef WalRcvExecResult *(*walrcv_exec_fn) (WalReceiverConn *conn, - const char *query, - const int nRetTypes, - const Oid *retTypes); + const char *query, + const int nRetTypes, + const Oid *retTypes); typedef void (*walrcv_disconnect_fn) (WalReceiverConn *conn); typedef struct WalReceiverFunctionsType { - walrcv_connect_fn walrcv_connect; - walrcv_check_conninfo_fn walrcv_check_conninfo; - walrcv_get_conninfo_fn walrcv_get_conninfo; - walrcv_identify_system_fn walrcv_identify_system; - walrcv_readtimelinehistoryfile_fn walrcv_readtimelinehistoryfile; - walrcv_startstreaming_fn walrcv_startstreaming; - walrcv_endstreaming_fn walrcv_endstreaming; - walrcv_receive_fn walrcv_receive; - walrcv_send_fn walrcv_send; - walrcv_create_slot_fn walrcv_create_slot; - walrcv_exec_fn walrcv_exec; - walrcv_disconnect_fn walrcv_disconnect; + walrcv_connect_fn walrcv_connect; + walrcv_check_conninfo_fn walrcv_check_conninfo; + walrcv_get_conninfo_fn walrcv_get_conninfo; + walrcv_identify_system_fn walrcv_identify_system; + walrcv_readtimelinehistoryfile_fn walrcv_readtimelinehistoryfile; + walrcv_startstreaming_fn walrcv_startstreaming; + walrcv_endstreaming_fn walrcv_endstreaming; + walrcv_receive_fn walrcv_receive; + walrcv_send_fn walrcv_send; + walrcv_create_slot_fn walrcv_create_slot; + walrcv_exec_fn walrcv_exec; + walrcv_disconnect_fn walrcv_disconnect; } WalReceiverFunctionsType; extern PGDLLIMPORT WalReceiverFunctionsType *WalReceiverFunctions; diff --git a/src/include/replication/worker_internal.h b/src/include/replication/worker_internal.h index 26788fec5c1..0654461305b 100644 --- a/src/include/replication/worker_internal.h +++ b/src/include/replication/worker_internal.h @@ -22,71 +22,71 @@ typedef struct LogicalRepWorker { /* Time at which this worker was launched. */ - TimestampTz launch_time; + TimestampTz launch_time; /* Indicates if this slot is used or free. */ - bool in_use; + bool in_use; /* Increased everytime the slot is taken by new worker. */ - uint16 generation; + uint16 generation; /* Pointer to proc array. NULL if not running. */ - PGPROC *proc; + PGPROC *proc; /* Database id to connect to. */ - Oid dbid; + Oid dbid; /* User to use for connection (will be same as owner of subscription). */ - Oid userid; + Oid userid; /* Subscription id for the worker. */ - Oid subid; + Oid subid; /* Used for initial table synchronization. */ - Oid relid; - char relstate; + Oid relid; + char relstate; XLogRecPtr relstate_lsn; slock_t relmutex; /* Stats. */ XLogRecPtr last_lsn; - TimestampTz last_send_time; - TimestampTz last_recv_time; + TimestampTz last_send_time; + TimestampTz last_recv_time; XLogRecPtr reply_lsn; - TimestampTz reply_time; + TimestampTz reply_time; } LogicalRepWorker; /* Main memory context for apply worker. Permanent during worker lifetime. */ -extern MemoryContext ApplyContext; +extern MemoryContext ApplyContext; /* libpqreceiver connection */ -extern struct WalReceiverConn *wrconn; +extern struct WalReceiverConn *wrconn; /* Worker and subscription objects. */ -extern Subscription *MySubscription; -extern LogicalRepWorker *MyLogicalRepWorker; +extern Subscription *MySubscription; +extern LogicalRepWorker *MyLogicalRepWorker; -extern bool in_remote_transaction; +extern bool in_remote_transaction; extern volatile sig_atomic_t got_SIGHUP; extern volatile sig_atomic_t got_SIGTERM; extern void logicalrep_worker_attach(int slot); extern LogicalRepWorker *logicalrep_worker_find(Oid subid, Oid relid, - bool only_running); + bool only_running); extern void logicalrep_worker_launch(Oid dbid, Oid subid, const char *subname, - Oid userid, Oid relid); + Oid userid, Oid relid); extern void logicalrep_worker_stop(Oid subid, Oid relid); extern void logicalrep_worker_wakeup(Oid subid, Oid relid); extern void logicalrep_worker_wakeup_ptr(LogicalRepWorker *worker); -extern int logicalrep_sync_worker_count(Oid subid); +extern int logicalrep_sync_worker_count(Oid subid); extern void logicalrep_worker_sighup(SIGNAL_ARGS); extern void logicalrep_worker_sigterm(SIGNAL_ARGS); extern char *LogicalRepSyncTableStart(XLogRecPtr *origin_startpos); -void process_syncing_tables(XLogRecPtr current_lsn); +void process_syncing_tables(XLogRecPtr current_lsn); void invalidate_syncing_table_states(Datum arg, int cacheid, - uint32 hashvalue); + uint32 hashvalue); static inline bool am_tablesync_worker(void) diff --git a/src/include/statistics/extended_stats_internal.h b/src/include/statistics/extended_stats_internal.h index 0c40b867164..dc72e2f4798 100644 --- a/src/include/statistics/extended_stats_internal.h +++ b/src/include/statistics/extended_stats_internal.h @@ -53,7 +53,7 @@ extern bytea *statext_ndistinct_serialize(MVNDistinct *ndistinct); extern MVNDistinct *statext_ndistinct_deserialize(bytea *data); extern MVDependencies *statext_dependencies_build(int numrows, HeapTuple *rows, - Bitmapset *attrs, VacAttrStats **stats); + Bitmapset *attrs, VacAttrStats **stats); extern bytea *statext_dependencies_serialize(MVDependencies *dependencies); extern MVDependencies *statext_dependencies_deserialize(bytea *data); @@ -61,9 +61,9 @@ extern MultiSortSupport multi_sort_init(int ndims); extern void multi_sort_add_dimension(MultiSortSupport mss, int sortdim, Oid oper); extern int multi_sort_compare(const void *a, const void *b, void *arg); -extern int multi_sort_compare_dim(int dim, const SortItem * a, - const SortItem * b, MultiSortSupport mss); -extern int multi_sort_compare_dims(int start, int end, const SortItem * a, - const SortItem * b, MultiSortSupport mss); +extern int multi_sort_compare_dim(int dim, const SortItem *a, + const SortItem *b, MultiSortSupport mss); +extern int multi_sort_compare_dims(int start, int end, const SortItem *a, + const SortItem *b, MultiSortSupport mss); #endif /* EXTENDED_STATS_INTERNAL_H */ diff --git a/src/include/storage/condition_variable.h b/src/include/storage/condition_variable.h index e57cec71051..89f5d5804bd 100644 --- a/src/include/storage/condition_variable.h +++ b/src/include/storage/condition_variable.h @@ -28,7 +28,7 @@ typedef struct { slock_t mutex; - proclist_head wakeup; + proclist_head wakeup; } ConditionVariable; /* Initialize a condition variable. */ @@ -54,6 +54,6 @@ extern void ConditionVariablePrepareToSleep(ConditionVariable *); /* Wake up a single waiter (via signal) or all waiters (via broadcast). */ extern bool ConditionVariableSignal(ConditionVariable *); -extern int ConditionVariableBroadcast(ConditionVariable *); +extern int ConditionVariableBroadcast(ConditionVariable *); #endif /* CONDITION_VARIABLE_H */ diff --git a/src/include/storage/proc.h b/src/include/storage/proc.h index 1a125d83f40..2fbde36dad2 100644 --- a/src/include/storage/proc.h +++ b/src/include/storage/proc.h @@ -113,7 +113,7 @@ struct PGPROC Oid databaseId; /* OID of database this backend is using */ Oid roleId; /* OID of role using this backend */ - bool isBackgroundWorker; /* true if background worker. */ + bool isBackgroundWorker; /* true if background worker. */ /* * While in hot standby mode, shows that a conflict signal has been sent diff --git a/src/include/storage/procarray.h b/src/include/storage/procarray.h index 805ecd25eca..22955a79dd4 100644 --- a/src/include/storage/procarray.h +++ b/src/include/storage/procarray.h @@ -27,13 +27,16 @@ * to avoid forcing to include proc.h when including procarray.h. So if you modify * PROC_XXX flags, you need to modify these flags. */ -#define PROCARRAY_VACUUM_FLAG 0x02 /* currently running lazy vacuum */ -#define PROCARRAY_ANALYZE_FLAG 0x04 /* currently running analyze */ -#define PROCARRAY_LOGICAL_DECODING_FLAG 0x10 /* currently doing logical - * decoding outside xact */ - -#define PROCARRAY_SLOTS_XMIN 0x20 /* replication slot xmin, - * catalog_xmin */ +#define PROCARRAY_VACUUM_FLAG 0x02 /* currently running + * lazy vacuum */ +#define PROCARRAY_ANALYZE_FLAG 0x04 /* currently running + * analyze */ +#define PROCARRAY_LOGICAL_DECODING_FLAG 0x10 /* currently doing + * logical decoding + * outside xact */ + +#define PROCARRAY_SLOTS_XMIN 0x20 /* replication slot + * xmin, catalog_xmin */ /* * Only flags in PROCARRAY_PROC_FLAGS_MASK are considered when matching * PGXACT->vacuumFlags. Other flags are used for different purposes and diff --git a/src/include/tcop/utility.h b/src/include/tcop/utility.h index 90f1215aec8..14f65c34d66 100644 --- a/src/include/tcop/utility.h +++ b/src/include/tcop/utility.h @@ -26,8 +26,8 @@ typedef enum /* Hook for plugins to get control in ProcessUtility() */ typedef void (*ProcessUtility_hook_type) (PlannedStmt *pstmt, const char *queryString, ProcessUtilityContext context, - ParamListInfo params, - QueryEnvironment *queryEnv, + ParamListInfo params, + QueryEnvironment *queryEnv, DestReceiver *dest, char *completionTag); extern PGDLLIMPORT ProcessUtility_hook_type ProcessUtility_hook; diff --git a/src/include/utils/jsonapi.h b/src/include/utils/jsonapi.h index 50c29c3a866..44ee36931eb 100644 --- a/src/include/utils/jsonapi.h +++ b/src/include/utils/jsonapi.h @@ -136,15 +136,15 @@ extern bool IsValidJsonNumber(const char *str, int len); typedef void (*JsonIterateStringValuesAction) (void *state, char *elem_value, int elem_len); /* an action that will be applied to each value in transform_json(b)_string_values functions */ -typedef text * (*JsonTransformStringValuesAction) (void *state, char *elem_value, int elem_len); +typedef text *(*JsonTransformStringValuesAction) (void *state, char *elem_value, int elem_len); extern void iterate_jsonb_string_values(Jsonb *jb, void *state, - JsonIterateStringValuesAction action); + JsonIterateStringValuesAction action); extern void iterate_json_string_values(text *json, void *action_state, - JsonIterateStringValuesAction action); + JsonIterateStringValuesAction action); extern Jsonb *transform_jsonb_string_values(Jsonb *jsonb, void *action_state, - JsonTransformStringValuesAction transform_action); + JsonTransformStringValuesAction transform_action); extern text *transform_json_string_values(text *json, void *action_state, - JsonTransformStringValuesAction transform_action); + JsonTransformStringValuesAction transform_action); #endif /* JSONAPI_H */ diff --git a/src/include/utils/lsyscache.h b/src/include/utils/lsyscache.h index a0d90e7e173..93588df9f74 100644 --- a/src/include/utils/lsyscache.h +++ b/src/include/utils/lsyscache.h @@ -86,7 +86,7 @@ extern Oid get_opfamily_proc(Oid opfamily, Oid lefttype, Oid righttype, extern char *get_attname(Oid relid, AttrNumber attnum); extern char *get_relid_attribute_name(Oid relid, AttrNumber attnum); extern AttrNumber get_attnum(Oid relid, const char *attname); -extern char get_attidentity(Oid relid, AttrNumber attnum); +extern char get_attidentity(Oid relid, AttrNumber attnum); extern Oid get_atttype(Oid relid, AttrNumber attnum); extern int32 get_atttypmod(Oid relid, AttrNumber attnum); extern void get_atttypetypmodcoll(Oid relid, AttrNumber attnum, diff --git a/src/include/utils/pg_locale.h b/src/include/utils/pg_locale.h index 439dfbdcafe..f0acc86b88a 100644 --- a/src/include/utils/pg_locale.h +++ b/src/include/utils/pg_locale.h @@ -68,20 +68,21 @@ extern void cache_locale_time(void); */ struct pg_locale_struct { - char provider; + char provider; union { #ifdef HAVE_LOCALE_T - locale_t lt; + locale_t lt; #endif #ifdef USE_ICU - struct { + struct + { const char *locale; - UCollator *ucol; - } icu; + UCollator *ucol; + } icu; #endif int dummy; /* in case we have neither LOCALE_T nor ICU */ - } info; + } info; }; typedef struct pg_locale_struct *pg_locale_t; diff --git a/src/include/utils/plancache.h b/src/include/utils/plancache.h index 9611f5a10c3..a129f2c652d 100644 --- a/src/include/utils/plancache.h +++ b/src/include/utils/plancache.h @@ -174,7 +174,7 @@ extern CachedPlanSource *CopyCachedPlan(CachedPlanSource *plansource); extern bool CachedPlanIsValid(CachedPlanSource *plansource); extern List *CachedPlanGetTargetList(CachedPlanSource *plansource, - QueryEnvironment *queryEnv); + QueryEnvironment *queryEnv); extern CachedPlan *GetCachedPlan(CachedPlanSource *plansource, ParamListInfo boundParams, diff --git a/src/include/utils/queryenvironment.h b/src/include/utils/queryenvironment.h index b4f65a19768..291b6fdbc23 100644 --- a/src/include/utils/queryenvironment.h +++ b/src/include/utils/queryenvironment.h @@ -31,14 +31,14 @@ typedef enum EphemeralNameRelationType */ typedef struct EphemeralNamedRelationMetadataData { - char *name; /* name used to identify the relation */ + char *name; /* name used to identify the relation */ /* only one of the next two fields should be used */ - Oid reliddesc; /* oid of relation to get tupdesc */ - TupleDesc tupdesc; /* description of result rows */ + Oid reliddesc; /* oid of relation to get tupdesc */ + TupleDesc tupdesc; /* description of result rows */ EphemeralNameRelationType enrtype; /* to identify type of relation */ - double enrtuples; /* estimated number of tuples */ + double enrtuples; /* estimated number of tuples */ } EphemeralNamedRelationMetadataData; typedef EphemeralNamedRelationMetadataData *EphemeralNamedRelationMetadata; @@ -49,7 +49,7 @@ typedef EphemeralNamedRelationMetadataData *EphemeralNamedRelationMetadata; */ typedef struct EphemeralNamedRelationData { - EphemeralNamedRelationMetadataData md; + EphemeralNamedRelationMetadataData md; void *reldata; /* structure for execution-time access to data */ } EphemeralNamedRelationData; diff --git a/src/include/utils/regproc.h b/src/include/utils/regproc.h index 70f47922ccc..ba46bd7d58d 100644 --- a/src/include/utils/regproc.h +++ b/src/include/utils/regproc.h @@ -1,7 +1,7 @@ /*------------------------------------------------------------------------- * * regproc.h - * Functions for the built-in types regproc, regclass, regtype, etc. + * Functions for the built-in types regproc, regclass, regtype, etc. * * Portions Copyright (c) 1996-2017, PostgreSQL Global Development Group * Portions Copyright (c) 1994, Regents of the University of California diff --git a/src/include/utils/rel.h b/src/include/utils/rel.h index ab875bb9d77..84768969d32 100644 --- a/src/include/utils/rel.h +++ b/src/include/utils/rel.h @@ -72,7 +72,7 @@ typedef struct PartitionKeyData bool *parttypbyval; char *parttypalign; Oid *parttypcoll; -} PartitionKeyData; +} PartitionKeyData; typedef struct PartitionKeyData *PartitionKey; @@ -146,7 +146,7 @@ typedef struct RelationData Bitmapset *rd_pkattr; /* cols included in primary key */ Bitmapset *rd_idattr; /* included in replica identity index */ - PublicationActions *rd_pubactions; /* publication actions */ + PublicationActions *rd_pubactions; /* publication actions */ /* * rd_options is set whenever rd_rel is loaded into the relcache entry. diff --git a/src/include/utils/varlena.h b/src/include/utils/varlena.h index b5994a1c72b..cab82ee888b 100644 --- a/src/include/utils/varlena.h +++ b/src/include/utils/varlena.h @@ -1,7 +1,7 @@ /*------------------------------------------------------------------------- * * varlena.h - * Functions for the variable-length built-in types. + * Functions for the variable-length built-in types. * * Portions Copyright (c) 1996-2017, PostgreSQL Global Development Group * Portions Copyright (c) 1994, Regents of the University of California |
