mirror of
https://github.com/postgres/postgres.git
synced 2025-04-29 13:56:47 +03:00
Replace magic constants used in pg_stat_get_replication_slot().
A few variables have been using 10 as a magic constant while PG_STAT_GET_REPLICATION_SLOT_COLS can be used instead. Author: Masahiko Sawada Reviewed-By: Amit Kapila Backpatch-through: 14, where it was introduced Discussion: https://postgr.es/m/CAD21AoBvqODDfmD17DkEuPCvV2KbruukXQ2Vwrv5Xi-TsAsTJA@mail.gmail.com
This commit is contained in:
parent
dfceed30ab
commit
a9cb00a965
@ -2317,8 +2317,8 @@ pg_stat_get_replication_slot(PG_FUNCTION_ARGS)
|
|||||||
text *slotname_text = PG_GETARG_TEXT_P(0);
|
text *slotname_text = PG_GETARG_TEXT_P(0);
|
||||||
NameData slotname;
|
NameData slotname;
|
||||||
TupleDesc tupdesc;
|
TupleDesc tupdesc;
|
||||||
Datum values[10];
|
Datum values[PG_STAT_GET_REPLICATION_SLOT_COLS];
|
||||||
bool nulls[10];
|
bool nulls[PG_STAT_GET_REPLICATION_SLOT_COLS];
|
||||||
PgStat_StatReplSlotEntry *slotent;
|
PgStat_StatReplSlotEntry *slotent;
|
||||||
PgStat_StatReplSlotEntry allzero;
|
PgStat_StatReplSlotEntry allzero;
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user