Remove extraneous blank lines before block-closing braces

These are useless and distracting.  We wouldn't have written the code
with them to begin with, so there's no reason to keep them.

Author: Justin Pryzby <pryzby@telsasoft.com>
Discussion: https://postgr.es/m/20220411020336.GB26620@telsasoft.com
Discussion: https://postgr.es/m/attachment/133167/0016-Extraneous-blank-lines.patch
This commit is contained in:
Alvaro Herrera 2022-04-13 19:14:20 +02:00
parent ed0fbc8e5a
commit 24d2b2680a
No known key found for this signature in database
GPG Key ID: 1C20ACB9D5C564AE
100 changed files with 2 additions and 138 deletions

View File

@ -104,7 +104,6 @@ gbt_bit_l2n(GBT_VARKEY *leaf, FmgrInfo *flinfo)
pfree(o); pfree(o);
return out; return out;
} }
static const gbtree_vinfo tinfo = static const gbtree_vinfo tinfo =

View File

@ -195,7 +195,6 @@ gbt_cash_penalty(PG_FUNCTION_ARGS)
penalty_num(result, origentry->lower, origentry->upper, newentry->lower, newentry->upper); penalty_num(result, origentry->lower, origentry->upper, newentry->lower, newentry->upper);
PG_RETURN_POINTER(result); PG_RETURN_POINTER(result);
} }
Datum Datum

View File

@ -190,7 +190,6 @@ gbt_float4_penalty(PG_FUNCTION_ARGS)
penalty_num(result, origentry->lower, origentry->upper, newentry->lower, newentry->upper); penalty_num(result, origentry->lower, origentry->upper, newentry->lower, newentry->upper);
PG_RETURN_POINTER(result); PG_RETURN_POINTER(result);
} }
Datum Datum

View File

@ -197,7 +197,6 @@ gbt_float8_penalty(PG_FUNCTION_ARGS)
penalty_num(result, origentry->lower, origentry->upper, newentry->lower, newentry->upper); penalty_num(result, origentry->lower, origentry->upper, newentry->lower, newentry->upper);
PG_RETURN_POINTER(result); PG_RETURN_POINTER(result);
} }
Datum Datum

View File

@ -165,7 +165,6 @@ gbt_inet_penalty(PG_FUNCTION_ARGS)
penalty_num(result, origentry->lower, origentry->upper, newentry->lower, newentry->upper); penalty_num(result, origentry->lower, origentry->upper, newentry->lower, newentry->upper);
PG_RETURN_POINTER(result); PG_RETURN_POINTER(result);
} }
Datum Datum

View File

@ -173,7 +173,6 @@ gbt_intv_compress(PG_FUNCTION_ARGS)
} }
PG_RETURN_POINTER(retval); PG_RETURN_POINTER(retval);
} }
Datum Datum
@ -276,7 +275,6 @@ gbt_intv_penalty(PG_FUNCTION_ARGS)
penalty_num(result, iorg[0], iorg[1], inew[0], inew[1]); penalty_num(result, iorg[0], iorg[1], inew[0], inew[1]);
PG_RETURN_POINTER(result); PG_RETURN_POINTER(result);
} }
Datum Datum

View File

@ -174,7 +174,6 @@ gbt_macad_penalty(PG_FUNCTION_ARGS)
penalty_num(result, iorg[0], iorg[1], inew[0], inew[1]); penalty_num(result, iorg[0], iorg[1], inew[0], inew[1]);
PG_RETURN_POINTER(result); PG_RETURN_POINTER(result);
} }
Datum Datum

View File

@ -174,7 +174,6 @@ gbt_macad8_penalty(PG_FUNCTION_ARGS)
penalty_num(result, iorg[0], iorg[1], inew[0], inew[1]); penalty_num(result, iorg[0], iorg[1], inew[0], inew[1]);
PG_RETURN_POINTER(result); PG_RETURN_POINTER(result);
} }
Datum Datum

View File

@ -377,7 +377,6 @@ gbt_ts_penalty(PG_FUNCTION_ARGS)
penalty_num(result, orgdbl[0], orgdbl[1], newdbl[0], newdbl[1]); penalty_num(result, orgdbl[0], orgdbl[1], newdbl[0], newdbl[1]);
PG_RETURN_POINTER(result); PG_RETURN_POINTER(result);
} }

View File

@ -1004,7 +1004,6 @@ materializeResult(FunctionCallInfo fcinfo, PGconn *conn, PGresult *res)
/* clean up GUC settings, if we changed any */ /* clean up GUC settings, if we changed any */
restoreLocalGucs(nestlevel); restoreLocalGucs(nestlevel);
} }
} }
PG_FINALLY(); PG_FINALLY();
@ -2635,7 +2634,6 @@ deleteConnection(const char *name)
ereport(ERROR, ereport(ERROR,
(errcode(ERRCODE_UNDEFINED_OBJECT), (errcode(ERRCODE_UNDEFINED_OBJECT),
errmsg("undefined connection name"))); errmsg("undefined connection name")));
} }
static void static void

View File

@ -210,7 +210,6 @@ makepol(WORKSTATE *state)
(errcode(ERRCODE_SYNTAX_ERROR), (errcode(ERRCODE_SYNTAX_ERROR),
errmsg("syntax error"))); errmsg("syntax error")));
return ERR; return ERR;
} }
} }

View File

@ -260,7 +260,6 @@ makepol(QPRS_STATE *state)
errmsg("syntax error"))); errmsg("syntax error")));
return ERR; return ERR;
} }
} }
while (lenstack) while (lenstack)

View File

@ -1849,7 +1849,6 @@ pg_stat_statements_internal(FunctionCallInfo fcinfo,
if (qbuffer) if (qbuffer)
free(qbuffer); free(qbuffer);
} }
/* Number of output arguments (columns) for pg_stat_statements_info */ /* Number of output arguments (columns) for pg_stat_statements_info */

View File

@ -1734,7 +1734,6 @@ postgres_fdw_get_connections(PG_FUNCTION_ARGS)
tuplestore_putvalues(rsinfo->setResult, rsinfo->setDesc, values, nulls); tuplestore_putvalues(rsinfo->setResult, rsinfo->setDesc, values, nulls);
} }
PG_RETURN_VOID(); PG_RETURN_VOID();
} }

View File

@ -497,12 +497,10 @@ check_foreign_key(PG_FUNCTION_ARGS)
nv, (is_char_type > 0) ? "'" : "", (k < nkeys) ? ", " : ""); nv, (is_char_type > 0) ? "'" : "", (k < nkeys) ? ", " : "");
} }
strcat(sql, " where "); strcat(sql, " where ");
} }
else else
/* DELETE */ /* DELETE */
snprintf(sql, sizeof(sql), "delete from %s where ", relname); snprintf(sql, sizeof(sql), "delete from %s where ", relname);
} }
/* /*

View File

@ -257,7 +257,6 @@ typedef struct BloomFilter
/* data of the bloom filter */ /* data of the bloom filter */
char data[FLEXIBLE_ARRAY_MEMBER]; char data[FLEXIBLE_ARRAY_MEMBER];
} BloomFilter; } BloomFilter;

View File

@ -527,7 +527,6 @@ ginPlaceToPage(GinBtree btree, GinBtreeStack *stack,
BufferGetBlockNumber(stack->buffer), BufferGetBlockNumber(stack->buffer),
BufferGetBlockNumber(rbuffer)); BufferGetBlockNumber(rbuffer));
} }
} }
else else
{ {

View File

@ -8481,7 +8481,6 @@ log_heap_new_cid(Relation relation, HeapTuple tup)
{ {
xlrec.cmin = InvalidCommandId; xlrec.cmin = InvalidCommandId;
xlrec.cmax = HeapTupleHeaderGetRawCommandId(hdr); xlrec.cmax = HeapTupleHeaderGetRawCommandId(hdr);
} }
xlrec.combocid = InvalidCommandId; xlrec.combocid = InvalidCommandId;
} }

View File

@ -2073,7 +2073,6 @@ lazy_scan_noprune(LVRelState *vacrel,
elog(ERROR, "unexpected HeapTupleSatisfiesVacuum result"); elog(ERROR, "unexpected HeapTupleSatisfiesVacuum result");
break; break;
} }
} }
vacrel->offnum = InvalidOffsetNumber; vacrel->offnum = InvalidOffsetNumber;

View File

@ -35,7 +35,6 @@ typedef struct
/* split point identifying fields (returned by _bt_findsplitloc) */ /* split point identifying fields (returned by _bt_findsplitloc) */
OffsetNumber firstrightoff; /* first origpage item on rightpage */ OffsetNumber firstrightoff; /* first origpage item on rightpage */
bool newitemonleft; /* new item goes on left, or right? */ bool newitemonleft; /* new item goes on left, or right? */
} SplitPoint; } SplitPoint;
typedef struct typedef struct

View File

@ -2116,14 +2116,12 @@ btoptions(Datum reloptions, bool validate)
offsetof(BTOptions, vacuum_cleanup_index_scale_factor)}, offsetof(BTOptions, vacuum_cleanup_index_scale_factor)},
{"deduplicate_items", RELOPT_TYPE_BOOL, {"deduplicate_items", RELOPT_TYPE_BOOL,
offsetof(BTOptions, deduplicate_items)} offsetof(BTOptions, deduplicate_items)}
}; };
return (bytea *) build_reloptions(reloptions, validate, return (bytea *) build_reloptions(reloptions, validate,
RELOPT_KIND_BTREE, RELOPT_KIND_BTREE,
sizeof(BTOptions), sizeof(BTOptions),
tab, lengthof(tab)); tab, lengthof(tab));
} }
/* /*
@ -2591,7 +2589,6 @@ _bt_check_natts(Relation rel, bool heapkeyspace, Page page, OffsetNumber offnum)
/* Use generic heapkeyspace pivot tuple handling */ /* Use generic heapkeyspace pivot tuple handling */
} }
} }
/* Handle heapkeyspace pivot tuples (excluding minus infinity items) */ /* Handle heapkeyspace pivot tuples (excluding minus infinity items) */

View File

@ -38,7 +38,6 @@ out_gistxlogDelete(StringInfo buf, gistxlogDelete *xlrec)
{ {
appendStringInfo(buf, "delete: latestRemovedXid %u, nitems: %u", appendStringInfo(buf, "delete: latestRemovedXid %u, nitems: %u",
xlrec->latestRemovedXid, xlrec->ntodelete); xlrec->latestRemovedXid, xlrec->ntodelete);
} }
static void static void

View File

@ -747,7 +747,6 @@ spgoptions(Datum reloptions, bool validate)
RELOPT_KIND_SPGIST, RELOPT_KIND_SPGIST,
sizeof(SpGistOptions), sizeof(SpGistOptions),
tab, lengthof(tab)); tab, lengthof(tab));
} }
/* /*

View File

@ -381,7 +381,6 @@ simple_table_tuple_update(Relation rel, ItemPointer otid,
elog(ERROR, "unrecognized table_tuple_update status: %u", result); elog(ERROR, "unrecognized table_tuple_update status: %u", result);
break; break;
} }
} }

View File

@ -1790,7 +1790,6 @@ PerformWalRecovery(void)
/* there are no WAL records following the checkpoint */ /* there are no WAL records following the checkpoint */
ereport(LOG, ereport(LOG,
(errmsg("redo is not required"))); (errmsg("redo is not required")));
} }
/* /*

View File

@ -1007,7 +1007,6 @@ get_object_address(ObjectType objtype, Node *object,
address.objectId = get_domain_constraint_oid(domaddr.objectId, address.objectId = get_domain_constraint_oid(domaddr.objectId,
constrname, missing_ok); constrname, missing_ok);
address.objectSubId = 0; address.objectSubId = 0;
} }
break; break;
case OBJECT_DATABASE: case OBJECT_DATABASE:
@ -5621,7 +5620,6 @@ getObjectIdentityParts(const ObjectAddress *object,
systable_endscan(rcscan); systable_endscan(rcscan);
table_close(defaclrel, AccessShareLock); table_close(defaclrel, AccessShareLock);
break; break;
} }
defacl = (Form_pg_default_acl) GETSTRUCT(tup); defacl = (Form_pg_default_acl) GETSTRUCT(tup);

View File

@ -167,7 +167,6 @@ StoreAttrDefault(Relation rel, AttrNumber attnum,
if (!missingIsNull) if (!missingIsNull)
pfree(DatumGetPointer(missingval)); pfree(DatumGetPointer(missingval));
} }
table_close(attrrel, RowExclusiveLock); table_close(attrrel, RowExclusiveLock);
heap_freetuple(atttup); heap_freetuple(atttup);

View File

@ -97,7 +97,6 @@ typedef struct CopyToStateData
FmgrInfo *out_functions; /* lookup info for output functions */ FmgrInfo *out_functions; /* lookup info for output functions */
MemoryContext rowcontext; /* per-row evaluation context */ MemoryContext rowcontext; /* per-row evaluation context */
uint64 bytes_processed; /* number of bytes processed so far */ uint64 bytes_processed; /* number of bytes processed so far */
} CopyToStateData; } CopyToStateData;
/* DestReceiver for COPY (query) TO */ /* DestReceiver for COPY (query) TO */

View File

@ -1570,7 +1570,6 @@ DropSubscription(DropSubscriptionStmt *stmt, bool isTopLevel)
*/ */
if (slotname) if (slotname)
ReplicationSlotDropAtPubNode(wrconn, slotname, false); ReplicationSlotDropAtPubNode(wrconn, slotname, false);
} }
PG_FINALLY(); PG_FINALLY();
{ {

View File

@ -945,7 +945,6 @@ DefineRelation(CreateStmt *stmt, char relkind, Oid ownerId,
ereport(ERROR, ereport(ERROR,
(errcode(ERRCODE_FEATURE_NOT_SUPPORTED), (errcode(ERRCODE_FEATURE_NOT_SUPPORTED),
errmsg("specifying a table access method is not supported on a partitioned table"))); errmsg("specifying a table access method is not supported on a partitioned table")));
} }
else if (RELKIND_HAS_TABLE_AM(relkind)) else if (RELKIND_HAS_TABLE_AM(relkind))
accessMethod = default_table_access_method; accessMethod = default_table_access_method;
@ -3773,7 +3772,6 @@ RenameConstraint(RenameStmt *stmt)
stmt->relation->inh), /* recursive? */ stmt->relation->inh), /* recursive? */
false, /* recursing? */ false, /* recursing? */
0 /* expected inhcount */ ); 0 /* expected inhcount */ );
} }
/* /*
@ -17451,7 +17449,6 @@ ComputePartitionAttrs(ParseState *pstate, Relation rel, List *partParams, AttrNu
errmsg("data type %s has no default operator class for access method \"%s\"", errmsg("data type %s has no default operator class for access method \"%s\"",
format_type_be(atttype), "btree"), format_type_be(atttype), "btree"),
errhint("You must specify a btree operator class or define a default btree operator class for the data type."))); errhint("You must specify a btree operator class or define a default btree operator class for the data type.")));
} }
} }
else else

View File

@ -1439,7 +1439,6 @@ ParallelQueryMain(dsm_segment *seg, shm_toc *toc)
paramexec_space = dsa_get_address(area, fpes->param_exec); paramexec_space = dsa_get_address(area, fpes->param_exec);
RestoreParamExecParams(paramexec_space, queryDesc->estate); RestoreParamExecParams(paramexec_space, queryDesc->estate);
} }
pwcxt.toc = toc; pwcxt.toc = toc;
pwcxt.seg = seg; pwcxt.seg = seg;

View File

@ -548,7 +548,6 @@ ExecSimpleRelationDelete(ResultRelInfo *resultRelInfo,
{ {
skip_tuple = !ExecBRDeleteTriggers(estate, epqstate, resultRelInfo, skip_tuple = !ExecBRDeleteTriggers(estate, epqstate, resultRelInfo,
tid, NULL, NULL); tid, NULL, NULL);
} }
if (!skip_tuple) if (!skip_tuple)

View File

@ -4119,7 +4119,6 @@ build_pertrans_for_aggref(AggStatePerTrans pertrans,
2, 2,
InvalidOid, InvalidOid,
(void *) aggstate, NULL); (void *) aggstate, NULL);
} }
/* /*

View File

@ -1674,5 +1674,4 @@ ExecReScanMergeJoin(MergeJoinState *node)
ExecReScan(node->js.ps.lefttree); ExecReScan(node->js.ps.lefttree);
if (node->js.ps.righttree->chgParam == NULL) if (node->js.ps.righttree->chgParam == NULL)
ExecReScan(node->js.ps.righttree); ExecReScan(node->js.ps.righttree);
} }

View File

@ -192,7 +192,6 @@ slot_compile_deform(LLVMJitContext *context, TupleDesc desc,
v_tupleheaderp = v_tupleheaderp =
l_load_struct_gep(b, v_heapslot, FIELDNO_HEAPTUPLETABLESLOT_TUPLE, l_load_struct_gep(b, v_heapslot, FIELDNO_HEAPTUPLETABLESLOT_TUPLE,
"tupleheader"); "tupleheader");
} }
else if (ops == &TTSOpsMinimalTuple) else if (ops == &TTSOpsMinimalTuple)
{ {
@ -357,7 +356,6 @@ slot_compile_deform(LLVMJitContext *context, TupleDesc desc,
LLVMAddCase(v_switch, v_attno, attcheckattnoblocks[attnum]); LLVMAddCase(v_switch, v_attno, attcheckattnoblocks[attnum]);
} }
} }
else else
{ {

View File

@ -2173,7 +2173,6 @@ llvm_compile_expr(ExprState *state)
""); "");
LLVMBuildBr(b, opblocks[opno + 1]); LLVMBuildBr(b, opblocks[opno + 1]);
} }
LLVMPositionBuilderAtEnd(b, b_no_init); LLVMPositionBuilderAtEnd(b, b_no_init);

View File

@ -1775,7 +1775,6 @@ parse_hba_auth_opt(char *name, char *val, HbaLine *hbaline,
hbaline->pam_use_hostname = true; hbaline->pam_use_hostname = true;
else else
hbaline->pam_use_hostname = false; hbaline->pam_use_hostname = false;
} }
else if (strcmp(name, "ldapurl") == 0) else if (strcmp(name, "ldapurl") == 0)
{ {

View File

@ -115,7 +115,6 @@ cx(PlannerInfo *root, Gene *tour1, Gene *tour2, Gene *offspring,
for (i = 0; i < num_gene; i++) for (i = 0; i < num_gene; i++)
if (tour1[i] != offspring[i]) if (tour1[i] != offspring[i])
num_diffs++; num_diffs++;
} }
return num_diffs; return num_diffs;

View File

@ -222,11 +222,9 @@ gimme_tour(PlannerInfo *root, Edge *edge_table, Gene *new_gene, int num_gene)
/* mark this node as incorporated */ /* mark this node as incorporated */
edge_table[(int) new_gene[i - 1]].unused_edges = -1; edge_table[(int) new_gene[i - 1]].unused_edges = -1;
} /* for (i=1; i<num_gene; i++) */ } /* for (i=1; i<num_gene; i++) */
return edge_failures; return edge_failures;
} }
/* remove_gene /* remove_gene
@ -337,7 +335,6 @@ gimme_gene(PlannerInfo *root, Edge edge, Edge *edge_table)
elog(ERROR, "minimum_count not set"); elog(ERROR, "minimum_count not set");
else if (edge_table[(int) friend].unused_edges == minimum_edges) else if (edge_table[(int) friend].unused_edges == minimum_edges)
minimum_count++; minimum_count++;
} /* for (i=0; i<edge.unused_edges; i++) */ } /* for (i=0; i<edge.unused_edges; i++) */

View File

@ -89,7 +89,6 @@ ox1(PlannerInfo *root, Gene *tour1, Gene *tour2, Gene *offspring, int num_gene,
} }
p = (p + 1) % num_gene; /* increment tour2-index */ p = (p + 1) % num_gene; /* increment tour2-index */
} }
} }
#endif /* defined(OX1) */ #endif /* defined(OX1) */

View File

@ -106,7 +106,6 @@ ox2(PlannerInfo *root, Gene *tour1, Gene *tour2, Gene *offspring, int num_gene,
/* city isn't used yet, so inherit from tour2 */ /* city isn't used yet, so inherit from tour2 */
offspring[k] = tour2[k]; offspring[k] = tour2[k];
} }
} }
#endif /* defined(OX2) */ #endif /* defined(OX2) */

View File

@ -131,7 +131,6 @@ pmx(PlannerInfo *root, Gene *tour1, Gene *tour2, Gene *offspring, int num_gene)
j++; j++;
} }
} }
if (!(found)) if (!(found))
@ -140,7 +139,6 @@ pmx(PlannerInfo *root, Gene *tour1, Gene *tour2, Gene *offspring, int num_gene)
indx[mx_fail] = k; indx[mx_fail] = k;
mx_fail++; mx_fail++;
} }
} /* ... for */ } /* ... for */
@ -172,9 +170,7 @@ pmx(PlannerInfo *root, Gene *tour1, Gene *tour2, Gene *offspring, int num_gene)
j++; j++;
} }
} /* ... for */ } /* ... for */
} /* ... if */ } /* ... if */
@ -206,12 +202,10 @@ pmx(PlannerInfo *root, Gene *tour1, Gene *tour2, Gene *offspring, int num_gene)
j++; j++;
} }
} /* ... if */ } /* ... if */
i++; i++;
} /* end while */ } /* end while */
} }
} /* ... for */ } /* ... for */

View File

@ -96,15 +96,12 @@ px(PlannerInfo *root, Gene *tour1, Gene *tour2, Gene *offspring, int num_gene,
{ /* next city in tour2 has been used */ { /* next city in tour2 has been used */
tour2_index++; tour2_index++;
} }
} }
else else
{ /* next position in offspring is filled */ { /* next position in offspring is filled */
offspring_index++; offspring_index++;
} }
} }
} }
#endif /* defined(PX) */ #endif /* defined(PX) */

View File

@ -6848,7 +6848,6 @@ create_partial_grouping_paths(PlannerInfo *root,
dNumPartialGroups)); dNumPartialGroups));
} }
} }
} }
if (can_sort && cheapest_partial_path != NULL) if (can_sort && cheapest_partial_path != NULL)

View File

@ -5853,7 +5853,6 @@ bgworker_should_start_now(BgWorkerStartTime start_time)
if (start_time == BgWorkerStart_PostmasterStart) if (start_time == BgWorkerStart_PostmasterStart)
return true; return true;
/* fall through */ /* fall through */
} }
return false; return false;

View File

@ -192,7 +192,6 @@ replorigin_check_prerequisites(bool check_slots, bool recoveryOK)
ereport(ERROR, ereport(ERROR,
(errcode(ERRCODE_READ_ONLY_SQL_TRANSACTION), (errcode(ERRCODE_READ_ONLY_SQL_TRANSACTION),
errmsg("cannot manipulate replication origins during recovery"))); errmsg("cannot manipulate replication origins during recovery")));
} }

View File

@ -1380,7 +1380,6 @@ SnapBuildFindSnapshot(SnapBuild *builder, XLogRecPtr lsn, xl_running_xacts *runn
* records so incremental cleanup can be performed. * records so incremental cleanup can be performed.
*/ */
return true; return true;
} }
/* --- /* ---

View File

@ -600,7 +600,6 @@ slot_fill_defaults(LogicalRepRelMapEntry *rel, EState *estate,
defmap[num_defaults] = attnum; defmap[num_defaults] = attnum;
num_defaults++; num_defaults++;
} }
} }
for (i = 0; i < num_defaults; i++) for (i = 0; i < num_defaults; i++)

View File

@ -1065,8 +1065,7 @@ pgoutput_column_list_init(PGOutputData *data, List *publications,
} }
ReleaseSysCache(cftuple); ReleaseSysCache(cftuple);
} /* loop all subscribed publications */ } /* loop all subscribed publications */
} }
/* /*

View File

@ -1000,7 +1000,6 @@ parseCreateReplSlotOptions(CreateReplicationSlotCmd *cmd,
(errcode(ERRCODE_INVALID_PARAMETER_VALUE), (errcode(ERRCODE_INVALID_PARAMETER_VALUE),
errmsg("unrecognized value for CREATE_REPLICATION_SLOT option \"%s\": \"%s\"", errmsg("unrecognized value for CREATE_REPLICATION_SLOT option \"%s\": \"%s\"",
defel->defname, action))); defel->defname, action)));
} }
else if (strcmp(defel->defname, "reserve_wal") == 0) else if (strcmp(defel->defname, "reserve_wal") == 0)
{ {

View File

@ -199,7 +199,6 @@ DependencyGenerator_free(DependencyGenerator state)
{ {
pfree(state->dependencies); pfree(state->dependencies);
pfree(state); pfree(state);
} }
/* generate next combination */ /* generate next combination */

View File

@ -2676,7 +2676,6 @@ CheckForBufferLeaks(void)
PrintBufferLeakWarning(res->buffer); PrintBufferLeakWarning(res->buffer);
RefCountErrors++; RefCountErrors++;
} }
} }
Assert(RefCountErrors == 0); Assert(RefCountErrors == 0);
@ -3652,7 +3651,6 @@ FlushRelationsAllBuffers(SMgrRelation *smgrs, int nrels)
break; break;
} }
} }
} }
else else
{ {

View File

@ -308,7 +308,6 @@ StrategyGetBuffer(BufferAccessStrategy strategy, uint32 *buf_state)
return buf; return buf;
} }
UnlockBufHdr(buf, local_buf_state); UnlockBufHdr(buf, local_buf_state);
} }
} }

View File

@ -648,7 +648,6 @@ SetLatch(Latch *latch)
*/ */
} }
#endif #endif
} }
/* /*

View File

@ -243,7 +243,6 @@ typedef struct ComputeXidHorizonsResult
* session's temporary tables. * session's temporary tables.
*/ */
TransactionId temp_oldest_nonremovable; TransactionId temp_oldest_nonremovable;
} ComputeXidHorizonsResult; } ComputeXidHorizonsResult;
/* /*
@ -1839,7 +1838,6 @@ ComputeXidHorizons(ComputeXidHorizonsResult *h)
/* Catalog tables need to consider all backends in this db */ /* Catalog tables need to consider all backends in this db */
h->catalog_oldest_nonremovable = h->catalog_oldest_nonremovable =
TransactionIdOlder(h->catalog_oldest_nonremovable, xmin); TransactionIdOlder(h->catalog_oldest_nonremovable, xmin);
} }
} }

View File

@ -1096,7 +1096,6 @@ LWLockQueueSelf(LWLock *lock, LWLockMode mode)
#ifdef LOCK_DEBUG #ifdef LOCK_DEBUG
pg_atomic_fetch_add_u32(&lock->nwaiters, 1); pg_atomic_fetch_add_u32(&lock->nwaiters, 1);
#endif #endif
} }
/* /*

View File

@ -563,7 +563,6 @@ compactify_tuples(itemIdCompact itemidbase, int nitems, Page page, bool presorte
/* update the line pointer to reference the new offset */ /* update the line pointer to reference the new offset */
lp->lp_off = upper; lp->lp_off = upper;
} }
/* move the remaining tuples. */ /* move the remaining tuples. */
@ -669,7 +668,6 @@ compactify_tuples(itemIdCompact itemidbase, int nitems, Page page, bool presorte
/* update the line pointer to reference the new offset */ /* update the line pointer to reference the new offset */
lp->lp_off = upper; lp->lp_off = upper;
} }
/* Copy the remaining chunk */ /* Copy the remaining chunk */

View File

@ -162,7 +162,6 @@ InitSync(void)
HASH_ELEM | HASH_BLOBS | HASH_CONTEXT); HASH_ELEM | HASH_BLOBS | HASH_CONTEXT);
pendingUnlinks = NIL; pendingUnlinks = NIL;
} }
} }
/* /*

View File

@ -2636,7 +2636,6 @@ exec_describe_statement_message(const char *stmt_name)
} }
else else
pq_putemptymessage('n'); /* NoData */ pq_putemptymessage('n'); /* NoData */
} }
/* /*

View File

@ -3741,7 +3741,6 @@ GetCommandLogLevel(Node *parsetree)
lev = LOGSTMT_ALL; lev = LOGSTMT_ALL;
break; break;
} }
} }
break; break;

View File

@ -569,7 +569,6 @@ pushval_morph(Datum opaque, TSQueryParserState state, char *strval, int lenval,
} }
pfree(prs.words); pfree(prs.words);
} }
else else
pushStop(state); pushStop(state);
@ -720,5 +719,4 @@ websearch_to_tsquery(PG_FUNCTION_ARGS)
PG_RETURN_DATUM(DirectFunctionCall2(websearch_to_tsquery_byid, PG_RETURN_DATUM(DirectFunctionCall2(websearch_to_tsquery_byid,
ObjectIdGetDatum(cfgId), ObjectIdGetDatum(cfgId),
PointerGetDatum(in))); PointerGetDatum(in)));
} }

View File

@ -584,7 +584,6 @@ hlparsetext(Oid cfgId, HeadlineParsedText *prs, TSQuery query, char *buf, int bu
else else
addHLParsedLex(prs, query, lexs, NULL); addHLParsedLex(prs, query, lexs, NULL);
} while (norms); } while (norms);
} while (type > 0); } while (type > 0);
FunctionCall1(&(prsobj->prsend), PointerGetDatum(prsdata)); FunctionCall1(&(prsobj->prsend), PointerGetDatum(prsdata));
@ -629,7 +628,6 @@ generateHeadline(HeadlineParsedText *prs)
memcpy(ptr, prs->fragdelim, prs->fragdelimlen); memcpy(ptr, prs->fragdelim, prs->fragdelimlen);
ptr += prs->fragdelimlen; ptr += prs->fragdelimlen;
} }
} }
if (wrd->replace) if (wrd->replace)
{ {

View File

@ -328,7 +328,6 @@ pgstat_prep_database_pending(Oid dboid)
NULL); NULL);
return entry_ref->pending; return entry_ref->pending;
} }
/* /*

View File

@ -3094,7 +3094,6 @@ convert_database_priv_string(text *priv_type_text)
}; };
return convert_any_priv_string(priv_type_text, database_priv_map); return convert_any_priv_string(priv_type_text, database_priv_map);
} }

View File

@ -1489,7 +1489,6 @@ json_object(PG_FUNCTION_ARGS)
pfree(result.data); pfree(result.data);
PG_RETURN_TEXT_P(rval); PG_RETURN_TEXT_P(rval);
} }
/* /*

View File

@ -851,7 +851,6 @@ datum_to_jsonb(Datum val, bool is_null, JsonbInState *result,
sem.object_field_start = jsonb_in_object_field_start; sem.object_field_start = jsonb_in_object_field_start;
pg_parse_json_or_ereport(lex, &sem); pg_parse_json_or_ereport(lex, &sem);
} }
break; break;
case JSONBTYPE_JSONB: case JSONBTYPE_JSONB:

View File

@ -4168,7 +4168,6 @@ json_strip_nulls(PG_FUNCTION_ARGS)
PG_RETURN_TEXT_P(cstring_to_text_with_len(state->strval->data, PG_RETURN_TEXT_P(cstring_to_text_with_len(state->strval->data,
state->strval->len)); state->strval->len));
} }
/* /*

View File

@ -1181,7 +1181,6 @@ multirange_minus_internal(Oid mltrngtypoid, TypeCacheEntry *rangetyp,
*/ */
range_count3++; range_count3++;
r2 = ++i2 >= range_count2 ? NULL : ranges2[i2]; r2 = ++i2 >= range_count2 ? NULL : ranges2[i2];
} }
else if (range_overlaps_internal(rangetyp, r1, r2)) else if (range_overlaps_internal(rangetyp, r1, r2))
{ {
@ -1200,7 +1199,6 @@ multirange_minus_internal(Oid mltrngtypoid, TypeCacheEntry *rangetyp,
break; break;
else else
r2 = ++i2 >= range_count2 ? NULL : ranges2[i2]; r2 = ++i2 >= range_count2 ? NULL : ranges2[i2];
} }
else else
{ {

View File

@ -868,7 +868,6 @@ translate(PG_FUNCTION_ARGS)
target += len; target += len;
retlen += len; retlen += len;
} }
} }
else else
{ {

View File

@ -9440,7 +9440,6 @@ get_rule_expr(Node *node, deparse_context *context,
get_rule_expr_paren((Node *) xexpr->args, context, false, node); get_rule_expr_paren((Node *) xexpr->args, context, false, node);
break; break;
} }
} }
if (xexpr->op == IS_XMLSERIALIZE) if (xexpr->op == IS_XMLSERIALIZE)
appendStringInfo(buf, " AS %s", appendStringInfo(buf, " AS %s",

View File

@ -3628,7 +3628,6 @@ estimate_num_groups_incremental(PlannerInfo *root, List *groupExprs,
*/ */
if (estinfo != NULL && varinfo2->isdefault) if (estinfo != NULL && varinfo2->isdefault)
estinfo->flags |= SELFLAG_USED_DEFAULT; estinfo->flags |= SELFLAG_USED_DEFAULT;
} }
/* we're done with this relation */ /* we're done with this relation */

View File

@ -4898,7 +4898,6 @@ timestamp_part_common(PG_FUNCTION_ARGS, bool retnumeric)
lowunits, format_type_be(TIMESTAMPOID)))); lowunits, format_type_be(TIMESTAMPOID))));
intresult = 0; intresult = 0;
} }
} }
else else
{ {
@ -5123,7 +5122,6 @@ timestamptz_part_common(PG_FUNCTION_ARGS, bool retnumeric)
lowunits, format_type_be(TIMESTAMPTZOID)))); lowunits, format_type_be(TIMESTAMPTZOID))));
intresult = 0; intresult = 0;
} }
} }
else if (type == RESERV) else if (type == RESERV)
{ {

View File

@ -2196,7 +2196,6 @@ insertStatEntry(MemoryContext persistentContext, TSVectorStat *stat, TSVector tx
else else
pnode->right = node; pnode->right = node;
} }
} }
else else
{ {

View File

@ -1710,7 +1710,6 @@ SearchCatCacheList(CatCache *cache,
* we'd better do so before we start marking the members as belonging * we'd better do so before we start marking the members as belonging
* to the list. * to the list.
*/ */
} }
PG_CATCH(); PG_CATCH();
{ {
@ -1962,7 +1961,6 @@ CatCacheCopyKeys(TupleDesc tupdesc, int nkeys, int *attnos,
att->attbyval, att->attbyval,
att->attlen); att->attlen);
} }
} }
/* /*

View File

@ -2683,7 +2683,6 @@ log_line_prefix(StringInfo buf, ErrorData *edata)
appendStringInfo(buf, "%*s", padding, psdisp); appendStringInfo(buf, "%*s", padding, psdisp);
else else
appendBinaryStringInfo(buf, psdisp, displen); appendBinaryStringInfo(buf, psdisp, displen);
} }
else if (padding != 0) else if (padding != 0)
appendStringInfoSpaces(buf, appendStringInfoSpaces(buf,
@ -2722,7 +2721,6 @@ log_line_prefix(StringInfo buf, ErrorData *edata)
appendStringInfo(buf, "(%s)", appendStringInfo(buf, "(%s)",
MyProcPort->remote_port); MyProcPort->remote_port);
} }
} }
else if (padding != 0) else if (padding != 0)
appendStringInfoSpaces(buf, appendStringInfoSpaces(buf,

View File

@ -5906,7 +5906,6 @@ InitializeWalConsistencyChecking(void)
/* checking should not be deferred again */ /* checking should not be deferred again */
Assert(!check_wal_consistency_checking_deferred); Assert(!check_wal_consistency_checking_deferred);
} }
} }
/* /*

View File

@ -620,7 +620,6 @@ GenerationBlockMarkEmpty(GenerationBlock *block)
block->nchunks = 0; block->nchunks = 0;
block->nfree = 0; block->nfree = 0;
block->freeptr = ((char *) block) + Generation_BLOCKHDRSZ; block->freeptr = ((char *) block) + Generation_BLOCKHDRSZ;
} }
/* /*

View File

@ -896,7 +896,6 @@ CreateAuxProcessResourceOwner(void)
* owner. (This needs to run after, e.g., ShutdownXLOG.) * owner. (This needs to run after, e.g., ShutdownXLOG.)
*/ */
on_shmem_exit(ReleaseAuxProcessResourcesCallback, 0); on_shmem_exit(ReleaseAuxProcessResourcesCallback, 0);
} }
/* /*

View File

@ -3186,7 +3186,6 @@ mergeonerun(Tuplesortstate *state)
{ {
stup.srctape = srcTapeIndex; stup.srctape = srcTapeIndex;
tuplesort_heap_replace_top(state, &stup); tuplesort_heap_replace_top(state, &stup);
} }
else else
{ {

View File

@ -2407,7 +2407,6 @@ setup_locale_encoding(void)
if (!check_locale_encoding(lc_ctype, encodingid) || if (!check_locale_encoding(lc_ctype, encodingid) ||
!check_locale_encoding(lc_collate, encodingid)) !check_locale_encoding(lc_collate, encodingid))
exit(1); /* check_locale_encoding printed the error */ exit(1); /* check_locale_encoding printed the error */
} }
@ -2486,7 +2485,6 @@ setup_text_search(void)
printf(_("The default text search configuration will be set to \"%s\".\n"), printf(_("The default text search configuration will be set to \"%s\".\n"),
default_text_search_config); default_text_search_config);
} }

View File

@ -1373,7 +1373,6 @@ dumpDatabases(PGconn *conn)
pg_fatal("could not re-open the output file \"%s\": %m", pg_fatal("could not re-open the output file \"%s\": %m",
filename); filename);
} }
} }
PQclear(res); PQclear(res);

View File

@ -98,7 +98,6 @@ extractPageMap(const char *datadir, XLogRecPtr startpoint, int tliIndex,
} }
extractPageInfo(xlogreader); extractPageInfo(xlogreader);
} while (xlogreader->EndRecPtr < endpoint); } while (xlogreader->EndRecPtr < endpoint);
/* /*

View File

@ -740,8 +740,6 @@ verify_file_checksum(verifier_context *context, manifest_file *m,
close(fd); close(fd);
return; return;
} }
} }
if (rc < 0) if (rc < 0)
report_backup_error(context, "could not read file \"%s\": %m", report_backup_error(context, "could not read file \"%s\": %m",

View File

@ -2622,7 +2622,6 @@ describeOneTableDetails(const char *schemaname,
PQgetvalue(result, i, 4)); PQgetvalue(result, i, 4));
printTableAddFooter(&cont, buf.data); printTableAddFooter(&cont, buf.data);
} }
PQclear(result); PQclear(result);
} }
@ -3172,7 +3171,6 @@ describeOneTableDetails(const char *schemaname,
case 4: case 4:
printfPQExpBuffer(&buf, _("Triggers firing on replica only:")); printfPQExpBuffer(&buf, _("Triggers firing on replica only:"));
break; break;
} }
printTableAddFooter(&cont, buf.data); printTableAddFooter(&cont, buf.data);
have_heading = true; have_heading = true;

View File

@ -316,7 +316,6 @@ get_prompt(promptStatus_t status, ConditionalStack cstack)
buf[0] = *p; buf[0] = *p;
buf[1] = '\0'; buf[1] = '\0';
break; break;
} }
esc = false; esc = false;
} }

View File

@ -658,7 +658,6 @@ json_lex(JsonLexContext *lex)
lex->token_type = JSON_TOKEN_FALSE; lex->token_type = JSON_TOKEN_FALSE;
else else
return JSON_INVALID_TOKEN; return JSON_INVALID_TOKEN;
} }
} /* end of switch */ } /* end of switch */
} }
@ -856,7 +855,6 @@ json_lex_string(JsonLexContext *lex)
lex->token_terminator = s + pg_encoding_mblen_bounded(lex->input_encoding, s); lex->token_terminator = s + pg_encoding_mblen_bounded(lex->input_encoding, s);
return JSON_ESCAPING_INVALID; return JSON_ESCAPING_INVALID;
} }
} }
else if (lex->strval != NULL) else if (lex->strval != NULL)
{ {
@ -865,7 +863,6 @@ json_lex_string(JsonLexContext *lex)
appendStringInfoChar(lex->strval, *s); appendStringInfoChar(lex->strval, *s);
} }
} }
if (hi_surrogate != -1) if (hi_surrogate != -1)

View File

@ -1173,7 +1173,6 @@ print_aligned_text(const printTableContent *cont, FILE *fout, bool is_pager)
if (opt_border == 2) if (opt_border == 2)
fputs(dformat->rightvrule, fout); fputs(dformat->rightvrule, fout);
fputc('\n', fout); fputc('\n', fout);
} while (more_lines); } while (more_lines);
} }

View File

@ -315,7 +315,6 @@ ECPGconnect(int lineno, int c, const char *name, const char *user, const char *p
ecpg_free(dbname); ecpg_free(dbname);
dbname = ecpg_strdup(envname, lineno); dbname = ecpg_strdup(envname, lineno);
} }
} }
if (dbname == NULL && connection_name == NULL) if (dbname == NULL && connection_name == NULL)

View File

@ -564,7 +564,6 @@ ecpg_get_data(const PGresult *results, int act_tuple, int act_field, int lineno,
} }
pval += size; pval += size;
} }
break; break;

View File

@ -1392,7 +1392,6 @@ ecpg_build_params(struct statement *stmt)
if (sqlda->sqln == desc_counter) if (sqlda->sqln == desc_counter)
desc_counter = 0; desc_counter = 0;
} }
} }
else else
{ {

View File

@ -191,7 +191,6 @@ ECPGtransactionStatus(const char *connection_name)
} }
return PQtransactionStatus(con->connection); return PQtransactionStatus(con->connection);
} }
bool bool

View File

@ -1740,7 +1740,6 @@ ParseDateTime(char *timestr, char *lowstr,
{ {
(*endstr)++; (*endstr)++;
continue; continue;
} }
/* otherwise, something is not right... */ /* otherwise, something is not right... */
else else

View File

@ -947,7 +947,6 @@ interval2tm(interval span, struct tm *tm, fsec_t *fsec)
{ {
tm->tm_year = span.month / MONTHS_PER_YEAR; tm->tm_year = span.month / MONTHS_PER_YEAR;
tm->tm_mon = span.month % MONTHS_PER_YEAR; tm->tm_mon = span.month % MONTHS_PER_YEAR;
} }
else else
{ {

View File

@ -1308,7 +1308,6 @@ PGTYPESnumeric_cmp(numeric *var1, numeric *var2)
errno = PGTYPES_NUM_BAD_NUMERIC; errno = PGTYPES_NUM_BAD_NUMERIC;
return INT_MAX; return INT_MAX;
} }
int int

View File

@ -863,8 +863,6 @@ PGTYPEStimestamp_add_interval(timestamp * tin, interval * span, timestamp * tout
{ {
if (TIMESTAMP_NOT_FINITE(*tin)) if (TIMESTAMP_NOT_FINITE(*tin))
*tout = *tin; *tout = *tin;
else else
{ {
if (span->month != 0) if (span->month != 0)
@ -873,7 +871,6 @@ PGTYPEStimestamp_add_interval(timestamp * tin, interval * span, timestamp * tout
*tm = &tt; *tm = &tt;
fsec_t fsec; fsec_t fsec;
if (timestamp2tm(*tin, NULL, tm, &fsec, NULL) != 0) if (timestamp2tm(*tin, NULL, tm, &fsec, NULL) != 0)
return -1; return -1;
tm->tm_mon += span->month; tm->tm_mon += span->month;
@ -898,12 +895,11 @@ PGTYPEStimestamp_add_interval(timestamp * tin, interval * span, timestamp * tout
return -1; return -1;
} }
*tin += span->time; *tin += span->time;
*tout = *tin; *tout = *tin;
} }
return 0;
return 0;
} }
@ -925,6 +921,5 @@ PGTYPEStimestamp_sub_interval(timestamp * tin, interval * span, timestamp * tout
tspan.month = -span->month; tspan.month = -span->month;
tspan.time = -span->time; tspan.time = -span->time;
return PGTYPEStimestamp_add_interval(tin, &tspan, tout); return PGTYPEStimestamp_add_interval(tin, &tspan, tout);
} }

View File

@ -664,7 +664,6 @@ PQconnectdbParams(const char *const *keywords,
(void) connectDBComplete(conn); (void) connectDBComplete(conn);
return conn; return conn;
} }
/* /*

View File

@ -1432,7 +1432,6 @@ initialize_SSL(PGconn *conn)
} }
SSLerrfree(err); SSLerrfree(err);
} }
} }

View File

@ -1243,7 +1243,6 @@ pltcl_trigger_handler(PG_FUNCTION_ARGS, pltcl_call_state *call_state,
for (i = 0; i < trigdata->tg_trigger->tgnargs; i++) for (i = 0; i < trigdata->tg_trigger->tgnargs; i++)
Tcl_ListObjAppendElement(NULL, tcl_cmd, Tcl_ListObjAppendElement(NULL, tcl_cmd,
Tcl_NewStringObj(utf_e2u(trigdata->tg_trigger->tgargs[i]), -1)); Tcl_NewStringObj(utf_e2u(trigdata->tg_trigger->tgargs[i]), -1));
} }
PG_CATCH(); PG_CATCH();
{ {

View File

@ -278,7 +278,6 @@ win32_langinfo(const char *ctype)
strcpy(r, codepage); strcpy(r, codepage);
} }
} }
} }
#endif #endif

View File

@ -89,5 +89,4 @@ rot13_passphrase(char *buf, int size, int rwflag, void *userdata)
} }
return strlen(buf); return strlen(buf);
} }