Fix typos in comments
The changes done in this commit impact comments with no direct user-visible changes, with fixes for incorrect function, variable or structure names. Author: Alexander Lakhin Discussion: https://postgr.es/m/e8c38840-596a-83d6-bd8d-cebc51111572@gmail.com
This commit is contained in:
parent
6fd8ae6888
commit
8961cb9a03
|
@ -1721,7 +1721,7 @@ case $os in
|
||||||
# Likewise for "kernel-abi"
|
# Likewise for "kernel-abi"
|
||||||
eabi* | gnueabi*)
|
eabi* | gnueabi*)
|
||||||
;;
|
;;
|
||||||
# VxWorks passes extra cpu info in the 4th filed.
|
# VxWorks passes extra cpu info in the 4th field.
|
||||||
simlinux | simwindows | spe)
|
simlinux | simwindows | spe)
|
||||||
;;
|
;;
|
||||||
# Now accept the basic system types.
|
# Now accept the basic system types.
|
||||||
|
|
|
@ -104,7 +104,7 @@ typedef struct BtreeCheckState
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* The rightlink and incomplete split flag of block one level down to the
|
* The rightlink and incomplete split flag of block one level down to the
|
||||||
* target page, which was visited last time via downlink from taget page.
|
* target page, which was visited last time via downlink from target page.
|
||||||
* We use it to check for missing downlinks.
|
* We use it to check for missing downlinks.
|
||||||
*/
|
*/
|
||||||
BlockNumber prevrightlink;
|
BlockNumber prevrightlink;
|
||||||
|
|
|
@ -15,7 +15,7 @@
|
||||||
((GISTIntArrayOptions *) PG_GET_OPCLASS_OPTIONS())->num_ranges : \
|
((GISTIntArrayOptions *) PG_GET_OPCLASS_OPTIONS())->num_ranges : \
|
||||||
G_INT_NUMRANGES_DEFAULT)
|
G_INT_NUMRANGES_DEFAULT)
|
||||||
|
|
||||||
/* gist_int_ops opclass options */
|
/* gist__int_ops opclass options */
|
||||||
typedef struct
|
typedef struct
|
||||||
{
|
{
|
||||||
int32 vl_len_; /* varlena header (do not touch directly!) */
|
int32 vl_len_; /* varlena header (do not touch directly!) */
|
||||||
|
@ -80,7 +80,7 @@ typedef char *BITVECP;
|
||||||
#define HASHVAL(val, siglen) (((unsigned int)(val)) % SIGLENBIT(siglen))
|
#define HASHVAL(val, siglen) (((unsigned int)(val)) % SIGLENBIT(siglen))
|
||||||
#define HASH(sign, val, siglen) SETBIT((sign), HASHVAL(val, siglen))
|
#define HASH(sign, val, siglen) SETBIT((sign), HASHVAL(val, siglen))
|
||||||
|
|
||||||
/* gist_intbig_ops opclass options */
|
/* gist__intbig_ops opclass options */
|
||||||
typedef struct
|
typedef struct
|
||||||
{
|
{
|
||||||
int32 vl_len_; /* varlena header (do not touch directly!) */
|
int32 vl_len_; /* varlena header (do not touch directly!) */
|
||||||
|
|
|
@ -580,8 +580,8 @@ gistXLogAssignLSN(void)
|
||||||
int dummy = 0;
|
int dummy = 0;
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* Records other than SWITCH_WAL must have content. We use an integer 0 to
|
* Records other than XLOG_SWITCH must have content. We use an integer 0
|
||||||
* follow the restriction.
|
* to follow the restriction.
|
||||||
*/
|
*/
|
||||||
XLogBeginInsert();
|
XLogBeginInsert();
|
||||||
XLogSetRecordFlags(XLOG_MARK_UNIMPORTANT);
|
XLogSetRecordFlags(XLOG_MARK_UNIMPORTANT);
|
||||||
|
|
|
@ -1223,7 +1223,7 @@ heap_set_tidrange(TableScanDesc sscan, ItemPointer mintid,
|
||||||
* Calculate the first block and the number of blocks we must scan. We
|
* Calculate the first block and the number of blocks we must scan. We
|
||||||
* could be more aggressive here and perform some more validation to try
|
* could be more aggressive here and perform some more validation to try
|
||||||
* and further narrow the scope of blocks to scan by checking if the
|
* and further narrow the scope of blocks to scan by checking if the
|
||||||
* lowerItem has an offset above MaxOffsetNumber. In this case, we could
|
* lowestItem has an offset above MaxOffsetNumber. In this case, we could
|
||||||
* advance startBlk by one. Likewise, if highestItem has an offset of 0
|
* advance startBlk by one. Likewise, if highestItem has an offset of 0
|
||||||
* we could scan one fewer blocks. However, such an optimization does not
|
* we could scan one fewer blocks. However, such an optimization does not
|
||||||
* seem worth troubling over, currently.
|
* seem worth troubling over, currently.
|
||||||
|
|
|
@ -816,7 +816,7 @@ heapam_relation_copy_for_cluster(Relation OldHeap, Relation NewHeap,
|
||||||
* If the last pages of the scan were empty, we would go to
|
* If the last pages of the scan were empty, we would go to
|
||||||
* the next phase while heap_blks_scanned != heap_blks_total.
|
* the next phase while heap_blks_scanned != heap_blks_total.
|
||||||
* Instead, to ensure that heap_blks_scanned is equivalent to
|
* Instead, to ensure that heap_blks_scanned is equivalent to
|
||||||
* total_heap_blks after the table scan phase, this parameter
|
* heap_blks_total after the table scan phase, this parameter
|
||||||
* is manually updated to the correct value when the table
|
* is manually updated to the correct value when the table
|
||||||
* scan finishes.
|
* scan finishes.
|
||||||
*/
|
*/
|
||||||
|
|
|
@ -198,8 +198,7 @@ heap_page_prune_opt(Relation relation, Buffer buffer)
|
||||||
/*
|
/*
|
||||||
* Now that we have buffer lock, get accurate information about the
|
* Now that we have buffer lock, get accurate information about the
|
||||||
* page's free space, and recheck the heuristic about whether to
|
* page's free space, and recheck the heuristic about whether to
|
||||||
* prune. (We needn't recheck PageIsPrunable, since no one else could
|
* prune.
|
||||||
* have pruned while we hold pin.)
|
|
||||||
*/
|
*/
|
||||||
if (PageIsFull(page) || PageGetHeapFreeSpace(page) < minfree)
|
if (PageIsFull(page) || PageGetHeapFreeSpace(page) < minfree)
|
||||||
{
|
{
|
||||||
|
@ -490,7 +489,7 @@ heap_page_prune(Relation relation, Buffer buffer,
|
||||||
*
|
*
|
||||||
* Due to its cost we also only want to call
|
* Due to its cost we also only want to call
|
||||||
* TransactionIdLimitedForOldSnapshots() if necessary, i.e. we might not have
|
* TransactionIdLimitedForOldSnapshots() if necessary, i.e. we might not have
|
||||||
* done so in heap_hot_prune_opt() if pd_prune_xid was old enough. But we
|
* done so in heap_page_prune_opt() if pd_prune_xid was old enough. But we
|
||||||
* still want to be able to remove rows that are too new to be removed
|
* still want to be able to remove rows that are too new to be removed
|
||||||
* according to prstate->vistest, but that can be removed based on
|
* according to prstate->vistest, but that can be removed based on
|
||||||
* old_snapshot_threshold. So we call TransactionIdLimitedForOldSnapshots() on
|
* old_snapshot_threshold. So we call TransactionIdLimitedForOldSnapshots() on
|
||||||
|
|
|
@ -2575,7 +2575,7 @@ lazy_vacuum_heap_page(LVRelState *vacrel, BlockNumber blkno, Buffer buffer,
|
||||||
END_CRIT_SECTION();
|
END_CRIT_SECTION();
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* Now that we have removed the LD_DEAD items from the page, once again
|
* Now that we have removed the LP_DEAD items from the page, once again
|
||||||
* check if the page has become all-visible. The page is already marked
|
* check if the page has become all-visible. The page is already marked
|
||||||
* dirty, exclusively locked, and, if needed, a full page image has been
|
* dirty, exclusively locked, and, if needed, a full page image has been
|
||||||
* emitted.
|
* emitted.
|
||||||
|
|
|
@ -119,7 +119,7 @@ static inline IndexTuple _bt_split_firstright(FindSplitData *state,
|
||||||
* righthand page (which is called firstrightoff), plus a boolean
|
* righthand page (which is called firstrightoff), plus a boolean
|
||||||
* indicating whether the new tuple goes on the left or right page. You
|
* indicating whether the new tuple goes on the left or right page. You
|
||||||
* can think of the returned state as a point _between_ two adjacent data
|
* can think of the returned state as a point _between_ two adjacent data
|
||||||
* items (laftleft and firstright data items) on an imaginary version of
|
* items (lastleft and firstright data items) on an imaginary version of
|
||||||
* origpage that already includes newitem. The bool is necessary to
|
* origpage that already includes newitem. The bool is necessary to
|
||||||
* disambiguate the case where firstrightoff == newitemoff (i.e. it is
|
* disambiguate the case where firstrightoff == newitemoff (i.e. it is
|
||||||
* sometimes needed to determine if the firstright tuple for the split is
|
* sometimes needed to determine if the firstright tuple for the split is
|
||||||
|
|
|
@ -809,7 +809,7 @@ SlruPhysicalWritePage(SlruCtl ctl, int pageno, int slotno, SlruWriteAll fdata)
|
||||||
}
|
}
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* During a WriteAll, we may already have the desired file open.
|
* During a SimpleLruWriteAll, we may already have the desired file open.
|
||||||
*/
|
*/
|
||||||
if (fdata)
|
if (fdata)
|
||||||
{
|
{
|
||||||
|
@ -864,7 +864,7 @@ SlruPhysicalWritePage(SlruCtl ctl, int pageno, int slotno, SlruWriteAll fdata)
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
/*
|
/*
|
||||||
* In the unlikely event that we exceed MAX_FLUSH_BUFFERS,
|
* In the unlikely event that we exceed MAX_WRITEALL_BUFFERS,
|
||||||
* fall back to treating it as a standalone write.
|
* fall back to treating it as a standalone write.
|
||||||
*/
|
*/
|
||||||
fdata = NULL;
|
fdata = NULL;
|
||||||
|
@ -1478,7 +1478,7 @@ SlruPagePrecedesTestOffset(SlruCtl ctl, int per_page, uint32 offset)
|
||||||
*
|
*
|
||||||
* This assumes every uint32 >= FirstNormalTransactionId is a valid key. It
|
* This assumes every uint32 >= FirstNormalTransactionId is a valid key. It
|
||||||
* assumes each value occupies a contiguous, fixed-size region of SLRU bytes.
|
* assumes each value occupies a contiguous, fixed-size region of SLRU bytes.
|
||||||
* (MultiXactMemberCtl separates flags from XIDs. AsyncCtl has
|
* (MultiXactMemberCtl separates flags from XIDs. NotifyCtl has
|
||||||
* variable-length entries, no keys, and no random access. These unit tests
|
* variable-length entries, no keys, and no random access. These unit tests
|
||||||
* do not apply to them.)
|
* do not apply to them.)
|
||||||
*/
|
*/
|
||||||
|
|
|
@ -1476,7 +1476,7 @@ err:
|
||||||
}
|
}
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* Helper function to ease writing of XLogRoutine->page_read callbacks.
|
* Helper function to ease writing of XLogReaderRoutine->page_read callbacks.
|
||||||
* If this function is used, caller must supply a segment_open callback in
|
* If this function is used, caller must supply a segment_open callback in
|
||||||
* 'state', as that is used here.
|
* 'state', as that is used here.
|
||||||
*
|
*
|
||||||
|
@ -1513,7 +1513,7 @@ WALRead(XLogReaderState *state,
|
||||||
/*
|
/*
|
||||||
* If the data we want is not in a segment we have open, close what we
|
* If the data we want is not in a segment we have open, close what we
|
||||||
* have (if anything) and open the next one, using the caller's
|
* have (if anything) and open the next one, using the caller's
|
||||||
* provided openSegment callback.
|
* provided segment_open callback.
|
||||||
*/
|
*/
|
||||||
if (state->seg.ws_file < 0 ||
|
if (state->seg.ws_file < 0 ||
|
||||||
!XLByteInSeg(recptr, state->seg.ws_segno, state->segcxt.ws_segsize) ||
|
!XLByteInSeg(recptr, state->seg.ws_segno, state->segcxt.ws_segsize) ||
|
||||||
|
|
|
@ -819,7 +819,7 @@ AlterOpFamily(AlterOpFamilyStmt *stmt)
|
||||||
Oid amoid, /* our AM's oid */
|
Oid amoid, /* our AM's oid */
|
||||||
opfamilyoid; /* oid of opfamily */
|
opfamilyoid; /* oid of opfamily */
|
||||||
int maxOpNumber, /* amstrategies value */
|
int maxOpNumber, /* amstrategies value */
|
||||||
optsProcNumber, /* amopclassopts value */
|
optsProcNumber, /* amoptsprocnum value */
|
||||||
maxProcNumber; /* amsupport value */
|
maxProcNumber; /* amsupport value */
|
||||||
HeapTuple tup;
|
HeapTuple tup;
|
||||||
Form_pg_am amform;
|
Form_pg_am amform;
|
||||||
|
@ -1321,7 +1321,7 @@ assignProcTypes(OpFamilyMember *member, Oid amoid, Oid typeoid,
|
||||||
/*
|
/*
|
||||||
* pg_amproc functions are indexed by (lefttype, righttype), but
|
* pg_amproc functions are indexed by (lefttype, righttype), but
|
||||||
* an equalimage function can only be called at CREATE INDEX time.
|
* an equalimage function can only be called at CREATE INDEX time.
|
||||||
* The same opclass opcintype OID is always used for leftype and
|
* The same opclass opcintype OID is always used for lefttype and
|
||||||
* righttype. Providing a cross-type routine isn't sensible.
|
* righttype. Providing a cross-type routine isn't sensible.
|
||||||
* Reject cross-type ALTER OPERATOR FAMILY ... ADD FUNCTION 4
|
* Reject cross-type ALTER OPERATOR FAMILY ... ADD FUNCTION 4
|
||||||
* statements here.
|
* statements here.
|
||||||
|
|
|
@ -974,8 +974,8 @@ AlterSubscription_refresh(Subscription *sub, bool copy_data,
|
||||||
*
|
*
|
||||||
* Even if new worker for this particular rel is restarted it
|
* Even if new worker for this particular rel is restarted it
|
||||||
* won't be able to make any progress as we hold exclusive
|
* won't be able to make any progress as we hold exclusive
|
||||||
* lock on subscription_rel till the transaction end. It will
|
* lock on pg_subscription_rel till the transaction end. It
|
||||||
* simply exit as there is no corresponding rel entry.
|
* will simply exit as there is no corresponding rel entry.
|
||||||
*
|
*
|
||||||
* This locking also ensures that the state of rels won't
|
* This locking also ensures that the state of rels won't
|
||||||
* change till we are done with this refresh operation.
|
* change till we are done with this refresh operation.
|
||||||
|
|
|
@ -2984,7 +2984,7 @@ MergeAttributes(List *schema, List *supers, char relpersistence,
|
||||||
* generated column, we'll take its generation expression in
|
* generated column, we'll take its generation expression in
|
||||||
* preference to the parent's. We must check that the child
|
* preference to the parent's. We must check that the child
|
||||||
* column doesn't specify a default value or identity, which
|
* column doesn't specify a default value or identity, which
|
||||||
* matches the rules for a single column in parse_util.c.
|
* matches the rules for a single column in parse_utilcmd.c.
|
||||||
*
|
*
|
||||||
* Conversely, if the parent column is not generated, the
|
* Conversely, if the parent column is not generated, the
|
||||||
* child column can't be either. (We used to allow that, but
|
* child column can't be either. (We used to allow that, but
|
||||||
|
@ -8017,7 +8017,7 @@ ATPrepDropExpression(Relation rel, AlterTableCmd *cmd, bool recurse, bool recurs
|
||||||
* is a bit complicated. GENERATED clauses must be attached to the column
|
* is a bit complicated. GENERATED clauses must be attached to the column
|
||||||
* definition and cannot be added later like DEFAULT, so if a child table
|
* definition and cannot be added later like DEFAULT, so if a child table
|
||||||
* has a generation expression that the parent does not have, the child
|
* has a generation expression that the parent does not have, the child
|
||||||
* column will necessarily be an attlocal column. So to implement ONLY
|
* column will necessarily be an attislocal column. So to implement ONLY
|
||||||
* here, we'd need extra code to update attislocal of the direct child
|
* here, we'd need extra code to update attislocal of the direct child
|
||||||
* tables, somewhat similar to how DROP COLUMN does it, so that the
|
* tables, somewhat similar to how DROP COLUMN does it, so that the
|
||||||
* resulting state can be properly dumped and restored.
|
* resulting state can be properly dumped and restored.
|
||||||
|
@ -10930,7 +10930,7 @@ ATExecAlterConstraint(Relation rel, AlterTableCmd *cmd, bool recurse,
|
||||||
}
|
}
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* ATExecConstrRecurse already invalidated relcache for the relations
|
* ATExecAlterConstrRecurse already invalidated relcache for the relations
|
||||||
* having the constraint itself; here we also invalidate for relations
|
* having the constraint itself; here we also invalidate for relations
|
||||||
* that have any triggers that are part of the constraint.
|
* that have any triggers that are part of the constraint.
|
||||||
*/
|
*/
|
||||||
|
|
|
@ -3004,7 +3004,7 @@ hashagg_batch_new(LogicalTape *input_tape, int setno,
|
||||||
}
|
}
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* read_spilled_tuple
|
* hashagg_batch_read
|
||||||
* read the next tuple from a batch's tape. Return NULL if no more.
|
* read the next tuple from a batch's tape. Return NULL if no more.
|
||||||
*/
|
*/
|
||||||
static MinimalTuple
|
static MinimalTuple
|
||||||
|
|
|
@ -2121,8 +2121,8 @@ llvm_compile_expr(ExprState *state)
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* pergroup = &aggstate->all_pergroups
|
* pergroup = &aggstate->all_pergroups
|
||||||
* [op->d.agg_strict_trans_check.setoff]
|
* [op->d.agg_trans.setoff]
|
||||||
* [op->d.agg_init_trans_check.transno];
|
* [op->d.agg_trans.transno];
|
||||||
*/
|
*/
|
||||||
v_allpergroupsp =
|
v_allpergroupsp =
|
||||||
l_load_struct_gep(b, v_aggstatep,
|
l_load_struct_gep(b, v_aggstatep,
|
||||||
|
|
|
@ -386,7 +386,7 @@ build_minmax_path(PlannerInfo *root, MinMaxAggInfo *mminfo,
|
||||||
ntest = makeNode(NullTest);
|
ntest = makeNode(NullTest);
|
||||||
ntest->nulltesttype = IS_NOT_NULL;
|
ntest->nulltesttype = IS_NOT_NULL;
|
||||||
ntest->arg = copyObject(mminfo->target);
|
ntest->arg = copyObject(mminfo->target);
|
||||||
/* we checked it wasn't a rowtype in find_minmax_aggs_walker */
|
/* we checked it wasn't a rowtype in can_minmax_aggs */
|
||||||
ntest->argisrow = false;
|
ntest->argisrow = false;
|
||||||
ntest->location = -1;
|
ntest->location = -1;
|
||||||
|
|
||||||
|
|
|
@ -957,7 +957,7 @@ stmtmulti: stmtmulti ';' toplevel_stmt
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* toplevel_stmt includes BEGIN and END. stmt does not include them, because
|
* toplevel_stmt includes BEGIN and END. stmt does not include them, because
|
||||||
* those words have different meanings in function bodys.
|
* those words have different meanings in function bodies.
|
||||||
*/
|
*/
|
||||||
toplevel_stmt:
|
toplevel_stmt:
|
||||||
stmt
|
stmt
|
||||||
|
|
|
@ -2340,7 +2340,7 @@ merge_default_partitions(PartitionMap *outer_map,
|
||||||
/*
|
/*
|
||||||
* The default partitions have to be joined with each other, so merge
|
* The default partitions have to be joined with each other, so merge
|
||||||
* them. Note that each of the default partitions isn't merged yet
|
* them. Note that each of the default partitions isn't merged yet
|
||||||
* (see, process_outer_partition()/process_innerer_partition()), so
|
* (see, process_outer_partition()/process_inner_partition()), so
|
||||||
* they should be merged successfully. The merged partition will act
|
* they should be merged successfully. The merged partition will act
|
||||||
* as the default partition of the join relation.
|
* as the default partition of the join relation.
|
||||||
*/
|
*/
|
||||||
|
|
|
@ -55,7 +55,7 @@ static PartitionDesc RelationBuildPartitionDesc(Relation rel,
|
||||||
* RelationGetPartitionDesc -- get partition descriptor, if relation is partitioned
|
* RelationGetPartitionDesc -- get partition descriptor, if relation is partitioned
|
||||||
*
|
*
|
||||||
* We keep two partdescs in relcache: rd_partdesc includes all partitions
|
* We keep two partdescs in relcache: rd_partdesc includes all partitions
|
||||||
* (even those being concurrently marked detached), while rd_partdesc_nodetach
|
* (even those being concurrently marked detached), while rd_partdesc_nodetached
|
||||||
* omits (some of) those. We store the pg_inherits.xmin value for the latter,
|
* omits (some of) those. We store the pg_inherits.xmin value for the latter,
|
||||||
* to determine whether it can be validly reused in each case, since that
|
* to determine whether it can be validly reused in each case, since that
|
||||||
* depends on the active snapshot.
|
* depends on the active snapshot.
|
||||||
|
|
|
@ -1885,7 +1885,7 @@ ReorderBufferStreamCommit(ReorderBuffer *rb, ReorderBufferTXN *txn)
|
||||||
/*
|
/*
|
||||||
* This is a PREPARED transaction, part of a two-phase commit. The
|
* This is a PREPARED transaction, part of a two-phase commit. The
|
||||||
* full cleanup will happen as part of the COMMIT PREPAREDs, so now
|
* full cleanup will happen as part of the COMMIT PREPAREDs, so now
|
||||||
* just truncate txn by removing changes and tuple_cids.
|
* just truncate txn by removing changes and tuplecids.
|
||||||
*/
|
*/
|
||||||
ReorderBufferTruncateTXN(rb, txn, true);
|
ReorderBufferTruncateTXN(rb, txn, true);
|
||||||
/* Reset the CheckXidAlive */
|
/* Reset the CheckXidAlive */
|
||||||
|
@ -4010,7 +4010,7 @@ ReorderBufferStreamTXN(ReorderBuffer *rb, ReorderBufferTXN *txn)
|
||||||
* After that we need to reuse the snapshot from the previous run.
|
* After that we need to reuse the snapshot from the previous run.
|
||||||
*
|
*
|
||||||
* Unlike DecodeCommit which adds xids of all the subtransactions in
|
* Unlike DecodeCommit which adds xids of all the subtransactions in
|
||||||
* snapshot's xip array via SnapBuildCommittedTxn, we can't do that here
|
* snapshot's xip array via SnapBuildCommitTxn, we can't do that here
|
||||||
* but we do add them to subxip array instead via ReorderBufferCopySnap.
|
* but we do add them to subxip array instead via ReorderBufferCopySnap.
|
||||||
* This allows the catalog changes made in subtransactions decoded till
|
* This allows the catalog changes made in subtransactions decoded till
|
||||||
* now to be visible.
|
* now to be visible.
|
||||||
|
|
|
@ -804,7 +804,7 @@ standby_priority_comparator(const void *a, const void *b)
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* We might have equal priority values; arbitrarily break ties by position
|
* We might have equal priority values; arbitrarily break ties by position
|
||||||
* in the WALSnd array. (This is utterly bogus, since that is arrival
|
* in the WalSnd array. (This is utterly bogus, since that is arrival
|
||||||
* order dependent, but there are regression tests that rely on it.)
|
* order dependent, but there are regression tests that rely on it.)
|
||||||
*/
|
*/
|
||||||
return sa->walsnd_index - sb->walsnd_index;
|
return sa->walsnd_index - sb->walsnd_index;
|
||||||
|
|
|
@ -3069,7 +3069,7 @@ AtEOXact_Files(bool isCommit)
|
||||||
/*
|
/*
|
||||||
* BeforeShmemExit_Files
|
* BeforeShmemExit_Files
|
||||||
*
|
*
|
||||||
* before_shmem_access hook to clean up temp files during backend shutdown.
|
* before_shmem_exit hook to clean up temp files during backend shutdown.
|
||||||
* Here, we want to clean up *all* temp files including interXact ones.
|
* Here, we want to clean up *all* temp files including interXact ones.
|
||||||
*/
|
*/
|
||||||
static void
|
static void
|
||||||
|
|
|
@ -151,7 +151,7 @@ struct WaitEventSet
|
||||||
#endif
|
#endif
|
||||||
};
|
};
|
||||||
|
|
||||||
/* A common WaitEventSet used to implement WatchLatch() */
|
/* A common WaitEventSet used to implement WaitLatch() */
|
||||||
static WaitEventSet *LatchWaitSet;
|
static WaitEventSet *LatchWaitSet;
|
||||||
|
|
||||||
/* The position of the latch in LatchWaitSet. */
|
/* The position of the latch in LatchWaitSet. */
|
||||||
|
|
|
@ -1754,7 +1754,7 @@ ComputeXidHorizons(ComputeXidHorizonsResult *h)
|
||||||
* current top-level xid any.
|
* current top-level xid any.
|
||||||
*
|
*
|
||||||
* Without an assigned xid we could use a horizon as aggressive as
|
* Without an assigned xid we could use a horizon as aggressive as
|
||||||
* ReadNewTransactionid(), but we can get away with the much cheaper
|
* GetNewTransactionId(), but we can get away with the much cheaper
|
||||||
* latestCompletedXid + 1: If this backend has no xid there, by
|
* latestCompletedXid + 1: If this backend has no xid there, by
|
||||||
* definition, can't be any newer changes in the temp table than
|
* definition, can't be any newer changes in the temp table than
|
||||||
* latestCompletedXid.
|
* latestCompletedXid.
|
||||||
|
|
|
@ -37,7 +37,7 @@
|
||||||
#define NUM_EMULATION_SEMAPHORES (NUM_SPINLOCK_SEMAPHORES + NUM_ATOMICS_SEMAPHORES)
|
#define NUM_EMULATION_SEMAPHORES (NUM_SPINLOCK_SEMAPHORES + NUM_ATOMICS_SEMAPHORES)
|
||||||
#else
|
#else
|
||||||
#define NUM_EMULATION_SEMAPHORES (NUM_SPINLOCK_SEMAPHORES)
|
#define NUM_EMULATION_SEMAPHORES (NUM_SPINLOCK_SEMAPHORES)
|
||||||
#endif /* DISABLE_ATOMICS */
|
#endif /* HAVE_ATOMICS */
|
||||||
|
|
||||||
PGSemaphore *SpinlockSemaArray;
|
PGSemaphore *SpinlockSemaArray;
|
||||||
|
|
||||||
|
|
|
@ -283,7 +283,7 @@ pgstat_beinit(void)
|
||||||
*
|
*
|
||||||
* Apart from auxiliary processes, MyBackendId, MyDatabaseId,
|
* Apart from auxiliary processes, MyBackendId, MyDatabaseId,
|
||||||
* session userid, and application_name must be set for a
|
* session userid, and application_name must be set for a
|
||||||
* backend (hence, this cannot be combined with pgbestat_beinit).
|
* backend (hence, this cannot be combined with pgstat_beinit).
|
||||||
* Note also that we must be inside a transaction if this isn't an aux
|
* Note also that we must be inside a transaction if this isn't an aux
|
||||||
* process, as we may need to do encoding conversion on some strings.
|
* process, as we may need to do encoding conversion on some strings.
|
||||||
* ----------
|
* ----------
|
||||||
|
|
|
@ -24,7 +24,7 @@
|
||||||
PgStat_PendingWalStats PendingWalStats = {0};
|
PgStat_PendingWalStats PendingWalStats = {0};
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* WAL usage counters saved from pgWALUsage at the previous call to
|
* WAL usage counters saved from pgWalUsage at the previous call to
|
||||||
* pgstat_report_wal(). This is used to calculate how much WAL usage
|
* pgstat_report_wal(). This is used to calculate how much WAL usage
|
||||||
* happens between pgstat_report_wal() calls, by subtracting
|
* happens between pgstat_report_wal() calls, by subtracting
|
||||||
* the previous counters from the current ones.
|
* the previous counters from the current ones.
|
||||||
|
|
|
@ -4717,8 +4717,8 @@ pg_has_role_id_id(PG_FUNCTION_ARGS)
|
||||||
* Convert text string to AclMode value.
|
* Convert text string to AclMode value.
|
||||||
*
|
*
|
||||||
* We use USAGE to denote whether the privileges of the role are accessible
|
* We use USAGE to denote whether the privileges of the role are accessible
|
||||||
* (has_privs), MEMBER to denote is_member, and MEMBER WITH GRANT OPTION
|
* (has_privs_of_role), MEMBER to denote is_member, and MEMBER WITH GRANT
|
||||||
* (or ADMIN OPTION) to denote is_admin. There is no ACL bit corresponding
|
* (or ADMIN) OPTION to denote is_admin. There is no ACL bit corresponding
|
||||||
* to MEMBER so we cheat and use ACL_CREATE for that. This convention
|
* to MEMBER so we cheat and use ACL_CREATE for that. This convention
|
||||||
* is shared only with pg_role_aclcheck, below.
|
* is shared only with pg_role_aclcheck, below.
|
||||||
*/
|
*/
|
||||||
|
|
|
@ -1012,7 +1012,7 @@ search_locale_enum(LPWSTR pStr, DWORD dwFlags, LPARAM lparam)
|
||||||
{
|
{
|
||||||
/*
|
/*
|
||||||
* If the enumerated locale does not have a hyphen ("en") OR the
|
* If the enumerated locale does not have a hyphen ("en") OR the
|
||||||
* lc_message input does not have an underscore ("English"), we only
|
* locale_name input does not have an underscore ("English"), we only
|
||||||
* need to compare the <Language> tags.
|
* need to compare the <Language> tags.
|
||||||
*/
|
*/
|
||||||
if (wcsrchr(pStr, '-') == NULL || wcsrchr(argv[0], '_') == NULL)
|
if (wcsrchr(pStr, '-') == NULL || wcsrchr(argv[0], '_') == NULL)
|
||||||
|
|
|
@ -4210,7 +4210,7 @@ estimate_multivariate_ndistinct(PlannerInfo *root, RelOptInfo *rel,
|
||||||
* Process complex expressions, not just simple Vars.
|
* Process complex expressions, not just simple Vars.
|
||||||
*
|
*
|
||||||
* First, we search for an exact match of an expression. If we
|
* First, we search for an exact match of an expression. If we
|
||||||
* find one, we can just discard the whole GroupExprInfo, with all
|
* find one, we can just discard the whole GroupVarInfo, with all
|
||||||
* the variables we extracted from it.
|
* the variables we extracted from it.
|
||||||
*
|
*
|
||||||
* Otherwise we inspect the individual vars, and try matching it
|
* Otherwise we inspect the individual vars, and try matching it
|
||||||
|
|
|
@ -453,7 +453,7 @@ pg_do_encoding_conversion(unsigned char *src, int len,
|
||||||
*
|
*
|
||||||
* The output is null-terminated.
|
* The output is null-terminated.
|
||||||
*
|
*
|
||||||
* If destlen < srclen * MAX_CONVERSION_LENGTH + 1, the converted output
|
* If destlen < srclen * MAX_CONVERSION_INPUT_LENGTH + 1, the converted output
|
||||||
* wouldn't necessarily fit in the output buffer, and the function will not
|
* wouldn't necessarily fit in the output buffer, and the function will not
|
||||||
* convert the whole input.
|
* convert the whole input.
|
||||||
*
|
*
|
||||||
|
|
|
@ -83,4 +83,4 @@ extern rewind_source *init_libpq_source(PGconn *conn);
|
||||||
/* in local_source.c */
|
/* in local_source.c */
|
||||||
extern rewind_source *init_local_source(const char *datadir);
|
extern rewind_source *init_local_source(const char *datadir);
|
||||||
|
|
||||||
#endif /* FETCH_H */
|
#endif /* REWIND_SOURCE_H */
|
||||||
|
|
|
@ -358,7 +358,7 @@ typedef struct TableAmRoutine
|
||||||
* allowed by the AM.
|
* allowed by the AM.
|
||||||
*
|
*
|
||||||
* Implementations can assume that scan_set_tidrange is always called
|
* Implementations can assume that scan_set_tidrange is always called
|
||||||
* before can_getnextslot_tidrange or after scan_rescan and before any
|
* before scan_getnextslot_tidrange or after scan_rescan and before any
|
||||||
* further calls to scan_getnextslot_tidrange.
|
* further calls to scan_getnextslot_tidrange.
|
||||||
*/
|
*/
|
||||||
void (*scan_set_tidrange) (TableScanDesc scan,
|
void (*scan_set_tidrange) (TableScanDesc scan,
|
||||||
|
|
|
@ -43,7 +43,7 @@ typedef struct
|
||||||
/*
|
/*
|
||||||
* Before calling toast_tuple_init, the caller must initialize the
|
* Before calling toast_tuple_init, the caller must initialize the
|
||||||
* following fields. Each array must have a length equal to
|
* following fields. Each array must have a length equal to
|
||||||
* ttc_rel->rd_att->natts. The tts_oldvalues and tts_oldisnull fields
|
* ttc_rel->rd_att->natts. The ttc_oldvalues and ttc_oldisnull fields
|
||||||
* should be NULL in the case of an insert.
|
* should be NULL in the case of an insert.
|
||||||
*/
|
*/
|
||||||
Relation ttc_rel; /* the relation that contains the tuple */
|
Relation ttc_rel; /* the relation that contains the tuple */
|
||||||
|
@ -53,9 +53,9 @@ typedef struct
|
||||||
bool *ttc_oldisnull; /* null flags from previous tuple */
|
bool *ttc_oldisnull; /* null flags from previous tuple */
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* Before calling toast_tuple_init, the caller should set tts_attr to
|
* Before calling toast_tuple_init, the caller should set ttc_attr to
|
||||||
* point to an array of ToastAttrInfo structures of a length equal to
|
* point to an array of ToastAttrInfo structures of a length equal to
|
||||||
* tts_rel->rd_att->natts. The contents of the array need not be
|
* ttc_rel->rd_att->natts. The contents of the array need not be
|
||||||
* initialized. ttc_flags also does not need to be initialized.
|
* initialized. ttc_flags also does not need to be initialized.
|
||||||
*/
|
*/
|
||||||
uint8 ttc_flags;
|
uint8 ttc_flags;
|
||||||
|
|
|
@ -29,7 +29,7 @@ struct PlanState; /* avoid including execnodes.h too */
|
||||||
#define QTW_EXAMINE_RTES_AFTER 0x20 /* examine RTE nodes after their
|
#define QTW_EXAMINE_RTES_AFTER 0x20 /* examine RTE nodes after their
|
||||||
* contents */
|
* contents */
|
||||||
#define QTW_DONT_COPY_QUERY 0x40 /* do not copy top Query */
|
#define QTW_DONT_COPY_QUERY 0x40 /* do not copy top Query */
|
||||||
#define QTW_EXAMINE_SORTGROUP 0x80 /* include SortGroupNode lists */
|
#define QTW_EXAMINE_SORTGROUP 0x80 /* include SortGroupClause lists */
|
||||||
|
|
||||||
/* callback function for check_functions_in_node */
|
/* callback function for check_functions_in_node */
|
||||||
typedef bool (*check_function_callback) (Oid func_id, void *context);
|
typedef bool (*check_function_callback) (Oid func_id, void *context);
|
||||||
|
|
|
@ -11,8 +11,8 @@
|
||||||
*
|
*
|
||||||
*-------------------------------------------------------------------------
|
*-------------------------------------------------------------------------
|
||||||
*/
|
*/
|
||||||
#ifndef QUERYJUBLE_H
|
#ifndef QUERYJUMBLE_H
|
||||||
#define QUERYJUBLE_H
|
#define QUERYJUMBLE_H
|
||||||
|
|
||||||
#include "nodes/parsenodes.h"
|
#include "nodes/parsenodes.h"
|
||||||
|
|
||||||
|
|
|
@ -317,7 +317,7 @@
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* Recover memory used for relcache entries when invalidated. See
|
* Recover memory used for relcache entries when invalidated. See
|
||||||
* RelationBuildDescr() in src/backend/utils/cache/relcache.c.
|
* RelationBuildDesc() in src/backend/utils/cache/relcache.c.
|
||||||
*
|
*
|
||||||
* This is active automatically for clobber-cache builds when clobbering is
|
* This is active automatically for clobber-cache builds when clobbering is
|
||||||
* active, but can be overridden here by explicitly defining
|
* active, but can be overridden here by explicitly defining
|
||||||
|
|
|
@ -1500,7 +1500,7 @@ getNotify(PGconn *conn)
|
||||||
}
|
}
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* Store the strings right after the PQnotify structure so it can all be
|
* Store the strings right after the PGnotify structure so it can all be
|
||||||
* freed at once. We don't use NAMEDATALEN because we don't want to tie
|
* freed at once. We don't use NAMEDATALEN because we don't want to tie
|
||||||
* this interface to a specific server name length.
|
* this interface to a specific server name length.
|
||||||
*/
|
*/
|
||||||
|
|
|
@ -872,7 +872,7 @@ extern ssize_t pg_GSS_write(PGconn *conn, const void *ptr, size_t len);
|
||||||
extern ssize_t pg_GSS_read(PGconn *conn, void *ptr, size_t len);
|
extern ssize_t pg_GSS_read(PGconn *conn, void *ptr, size_t len);
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
/* === in libpq-trace.c === */
|
/* === in fe-trace.c === */
|
||||||
|
|
||||||
extern void pqTraceOutputMessage(PGconn *conn, const char *message,
|
extern void pqTraceOutputMessage(PGconn *conn, const char *message,
|
||||||
bool toServer);
|
bool toServer);
|
||||||
|
|
|
@ -2125,7 +2125,7 @@ plperl_create_sub(plperl_proc_desc *prodesc, const char *s, Oid fn_oid)
|
||||||
/*
|
/*
|
||||||
* G_KEEPERR seems to be needed here, else we don't recognize compile
|
* G_KEEPERR seems to be needed here, else we don't recognize compile
|
||||||
* errors properly. Perhaps it's because there's another level of eval
|
* errors properly. Perhaps it's because there's another level of eval
|
||||||
* inside mksafefunc?
|
* inside mkfunc?
|
||||||
*/
|
*/
|
||||||
count = call_pv("PostgreSQL::InServer::mkfunc",
|
count = call_pv("PostgreSQL::InServer::mkfunc",
|
||||||
G_SCALAR | G_EVAL | G_KEEPERR);
|
G_SCALAR | G_EVAL | G_KEEPERR);
|
||||||
|
|
|
@ -1,7 +1,7 @@
|
||||||
|
|
||||||
# Copyright (c) 2021-2023, PostgreSQL Global Development Group
|
# Copyright (c) 2021-2023, PostgreSQL Global Development Group
|
||||||
|
|
||||||
# Test for point-in-time-recovery (PITR) with prepared transactions
|
# Test for point-in-time recovery (PITR) with prepared transactions
|
||||||
use strict;
|
use strict;
|
||||||
use warnings;
|
use warnings;
|
||||||
use PostgreSQL::Test::Cluster;
|
use PostgreSQL::Test::Cluster;
|
||||||
|
|
|
@ -149,7 +149,7 @@ $node_publisher->safe_psql('postgres', "DROP TABLE tab_rep_next");
|
||||||
$node_subscriber->safe_psql('postgres', "DROP TABLE tab_rep_next");
|
$node_subscriber->safe_psql('postgres', "DROP TABLE tab_rep_next");
|
||||||
$node_subscriber->safe_psql('postgres', "DROP SUBSCRIPTION tap_sub");
|
$node_subscriber->safe_psql('postgres', "DROP SUBSCRIPTION tap_sub");
|
||||||
|
|
||||||
# Table tap_rep already has the same records on both publisher and subscriber
|
# Table tab_rep already has the same records on both publisher and subscriber
|
||||||
# at this time. Recreate the subscription which will do the initial copy of
|
# at this time. Recreate the subscription which will do the initial copy of
|
||||||
# the table again and fails due to unique constraint violation.
|
# the table again and fails due to unique constraint violation.
|
||||||
$node_subscriber->safe_psql('postgres',
|
$node_subscriber->safe_psql('postgres',
|
||||||
|
|
Loading…
Reference in New Issue