mirror of
https://github.com/postgres/postgres.git
synced 2025-11-04 20:11:56 +03:00
Post-PG 10 beta1 pgindent run
perltidy run not included.
This commit is contained in:
15
src/backend/utils/cache/inval.c
vendored
15
src/backend/utils/cache/inval.c
vendored
@@ -386,10 +386,9 @@ AddRelcacheInvalidationMessage(InvalidationListHeader *hdr,
|
||||
SharedInvalidationMessage msg;
|
||||
|
||||
/*
|
||||
* Don't add a duplicate item.
|
||||
* We assume dbId need not be checked because it will never change.
|
||||
* InvalidOid for relId means all relations so we don't need to add
|
||||
* individual ones when it is present.
|
||||
* Don't add a duplicate item. We assume dbId need not be checked because
|
||||
* it will never change. InvalidOid for relId means all relations so we
|
||||
* don't need to add individual ones when it is present.
|
||||
*/
|
||||
ProcessMessageList(hdr->rclist,
|
||||
if (msg->rc.id == SHAREDINVALRELCACHE_ID &&
|
||||
@@ -523,8 +522,8 @@ RegisterRelcacheInvalidation(Oid dbId, Oid relId)
|
||||
|
||||
/*
|
||||
* If the relation being invalidated is one of those cached in the local
|
||||
* relcache init file, mark that we need to zap that file at commit.
|
||||
* Same is true when we are invalidating whole relcache.
|
||||
* relcache init file, mark that we need to zap that file at commit. Same
|
||||
* is true when we are invalidating whole relcache.
|
||||
*/
|
||||
if (OidIsValid(dbId) &&
|
||||
(RelationIdIsInInitFile(relId) || relId == InvalidOid))
|
||||
@@ -1139,8 +1138,8 @@ CacheInvalidateHeapTuple(Relation relation,
|
||||
RegisterCatcacheInvalidation);
|
||||
|
||||
/*
|
||||
* Now, is this tuple one of the primary definers of a relcache entry?
|
||||
* See comments in file header for deeper explanation.
|
||||
* Now, is this tuple one of the primary definers of a relcache entry? See
|
||||
* comments in file header for deeper explanation.
|
||||
*
|
||||
* Note we ignore newtuple here; we assume an update cannot move a tuple
|
||||
* from being part of one relcache entry to being part of another.
|
||||
|
||||
2
src/backend/utils/cache/lsyscache.c
vendored
2
src/backend/utils/cache/lsyscache.c
vendored
@@ -858,7 +858,7 @@ get_attidentity(Oid relid, AttrNumber attnum)
|
||||
if (HeapTupleIsValid(tp))
|
||||
{
|
||||
Form_pg_attribute att_tup = (Form_pg_attribute) GETSTRUCT(tp);
|
||||
char result;
|
||||
char result;
|
||||
|
||||
result = att_tup->attidentity;
|
||||
ReleaseSysCache(tp);
|
||||
|
||||
4
src/backend/utils/cache/plancache.c
vendored
4
src/backend/utils/cache/plancache.c
vendored
@@ -89,7 +89,7 @@ static CachedPlanSource *first_saved_plan = NULL;
|
||||
|
||||
static void ReleaseGenericPlan(CachedPlanSource *plansource);
|
||||
static List *RevalidateCachedQuery(CachedPlanSource *plansource,
|
||||
QueryEnvironment *queryEnv);
|
||||
QueryEnvironment *queryEnv);
|
||||
static bool CheckCachedPlan(CachedPlanSource *plansource);
|
||||
static CachedPlan *BuildCachedPlan(CachedPlanSource *plansource, List *qlist,
|
||||
ParamListInfo boundParams, QueryEnvironment *queryEnv);
|
||||
@@ -1520,7 +1520,7 @@ AcquireExecutorLocks(List *stmt_list, bool acquire)
|
||||
* acquire a non-conflicting lock.
|
||||
*/
|
||||
if (list_member_int(plannedstmt->resultRelations, rt_index) ||
|
||||
list_member_int(plannedstmt->nonleafResultRelations, rt_index))
|
||||
list_member_int(plannedstmt->nonleafResultRelations, rt_index))
|
||||
lockmode = RowExclusiveLock;
|
||||
else if ((rc = get_plan_rowmark(plannedstmt->rowMarks, rt_index)) != NULL &&
|
||||
RowMarkRequiresRowShareLock(rc->markType))
|
||||
|
||||
16
src/backend/utils/cache/relcache.c
vendored
16
src/backend/utils/cache/relcache.c
vendored
@@ -4504,7 +4504,10 @@ RelationGetStatExtList(Relation relation)
|
||||
*/
|
||||
result = NIL;
|
||||
|
||||
/* Prepare to scan pg_statistic_ext for entries having stxrelid = this rel. */
|
||||
/*
|
||||
* Prepare to scan pg_statistic_ext for entries having stxrelid = this
|
||||
* rel.
|
||||
*/
|
||||
ScanKeyInit(&skey,
|
||||
Anum_pg_statistic_ext_stxrelid,
|
||||
BTEqualStrategyNumber, F_OIDEQ,
|
||||
@@ -4603,9 +4606,10 @@ RelationSetIndexList(Relation relation, List *indexIds, Oid oidIndex)
|
||||
list_free(relation->rd_indexlist);
|
||||
relation->rd_indexlist = indexIds;
|
||||
relation->rd_oidindex = oidIndex;
|
||||
|
||||
/*
|
||||
* For the moment, assume the target rel hasn't got a pk or replica
|
||||
* index. We'll load them on demand in the API that wraps access to them.
|
||||
* For the moment, assume the target rel hasn't got a pk or replica index.
|
||||
* We'll load them on demand in the API that wraps access to them.
|
||||
*/
|
||||
relation->rd_pkindex = InvalidOid;
|
||||
relation->rd_replidindex = InvalidOid;
|
||||
@@ -5169,7 +5173,7 @@ GetRelationPublicationActions(Relation relation)
|
||||
{
|
||||
List *puboids;
|
||||
ListCell *lc;
|
||||
MemoryContext oldcxt;
|
||||
MemoryContext oldcxt;
|
||||
PublicationActions *pubactions = palloc0(sizeof(PublicationActions));
|
||||
|
||||
if (relation->rd_pubactions)
|
||||
@@ -5200,8 +5204,8 @@ GetRelationPublicationActions(Relation relation)
|
||||
ReleaseSysCache(tup);
|
||||
|
||||
/*
|
||||
* If we know everything is replicated, there is no point to check
|
||||
* for other publications.
|
||||
* If we know everything is replicated, there is no point to check for
|
||||
* other publications.
|
||||
*/
|
||||
if (pubactions->pubinsert && pubactions->pubupdate &&
|
||||
pubactions->pubdelete)
|
||||
|
||||
16
src/backend/utils/cache/syscache.c
vendored
16
src/backend/utils/cache/syscache.c
vendored
@@ -661,7 +661,7 @@ static const struct cachedesc cacheinfo[] = {
|
||||
},
|
||||
16
|
||||
},
|
||||
{PublicationRelationId, /* PUBLICATIONOID */
|
||||
{PublicationRelationId, /* PUBLICATIONOID */
|
||||
PublicationObjectIndexId,
|
||||
1,
|
||||
{
|
||||
@@ -672,7 +672,7 @@ static const struct cachedesc cacheinfo[] = {
|
||||
},
|
||||
8
|
||||
},
|
||||
{PublicationRelationId, /* PUBLICATIONNAME */
|
||||
{PublicationRelationId, /* PUBLICATIONNAME */
|
||||
PublicationNameIndexId,
|
||||
1,
|
||||
{
|
||||
@@ -683,7 +683,7 @@ static const struct cachedesc cacheinfo[] = {
|
||||
},
|
||||
8
|
||||
},
|
||||
{PublicationRelRelationId, /* PUBLICATIONREL */
|
||||
{PublicationRelRelationId, /* PUBLICATIONREL */
|
||||
PublicationRelObjectIndexId,
|
||||
1,
|
||||
{
|
||||
@@ -694,7 +694,7 @@ static const struct cachedesc cacheinfo[] = {
|
||||
},
|
||||
64
|
||||
},
|
||||
{PublicationRelRelationId, /* PUBLICATIONRELMAP */
|
||||
{PublicationRelRelationId, /* PUBLICATIONRELMAP */
|
||||
PublicationRelPrrelidPrpubidIndexId,
|
||||
2,
|
||||
{
|
||||
@@ -716,7 +716,7 @@ static const struct cachedesc cacheinfo[] = {
|
||||
},
|
||||
8
|
||||
},
|
||||
{SequenceRelationId, /* SEQRELID */
|
||||
{SequenceRelationId, /* SEQRELID */
|
||||
SequenceRelidIndexId,
|
||||
1,
|
||||
{
|
||||
@@ -760,7 +760,7 @@ static const struct cachedesc cacheinfo[] = {
|
||||
},
|
||||
128
|
||||
},
|
||||
{SubscriptionRelationId, /* SUBSCRIPTIONOID */
|
||||
{SubscriptionRelationId, /* SUBSCRIPTIONOID */
|
||||
SubscriptionObjectIndexId,
|
||||
1,
|
||||
{
|
||||
@@ -771,7 +771,7 @@ static const struct cachedesc cacheinfo[] = {
|
||||
},
|
||||
4
|
||||
},
|
||||
{SubscriptionRelationId, /* SUBSCRIPTIONNAME */
|
||||
{SubscriptionRelationId, /* SUBSCRIPTIONNAME */
|
||||
SubscriptionNameIndexId,
|
||||
2,
|
||||
{
|
||||
@@ -782,7 +782,7 @@ static const struct cachedesc cacheinfo[] = {
|
||||
},
|
||||
4
|
||||
},
|
||||
{SubscriptionRelRelationId, /* SUBSCRIPTIONRELMAP */
|
||||
{SubscriptionRelRelationId, /* SUBSCRIPTIONRELMAP */
|
||||
SubscriptionRelSrrelidSrsubidIndexId,
|
||||
2,
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user