forked frompostgres/postgres
- Notifications
You must be signed in to change notification settings - Fork6
Commit96bdb7e
committed
Fix pgstat_report_replslot() to use proper data types for its arguments.
The caller of pgstat_report_replslot() passes int64 values to the function.Also the function stores those values in PgStat_Counter (i.e., int64) fieldsof PgStat_MsgReplSlot struct. But previously the function used "int" asthe data types of some arguments for those values, which could lead tothe overflow of values.To avoid this risk, this commit fixes pgstat_report_replslot() to usePgStat_Counter type for the arguments. Since they are the statistics counters,PgStat_Counter, the data type used for counters, is used for theminstead of int64.Reported-by: Vignesh CAuthor: Vignesh CReviewed-by: Jeevan Ladhe, Fujii MasaoDiscussion:https://postgr.es/m/CALDaNm080OpG=ZwOb0i8EyChH5SyHAMFWJCKaKTXmrfvJLbgaA@mail.gmail.com1 parent6fb66c2 commit96bdb7e
2 files changed
+8
-4
lines changedLines changed: 4 additions & 2 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
1773 | 1773 |
| |
1774 | 1774 |
| |
1775 | 1775 |
| |
1776 |
| - | |
1777 |
| - | |
| 1776 | + | |
| 1777 | + | |
| 1778 | + | |
| 1779 | + | |
1778 | 1780 |
| |
1779 | 1781 |
| |
1780 | 1782 |
| |
|
Lines changed: 4 additions & 2 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
1450 | 1450 |
| |
1451 | 1451 |
| |
1452 | 1452 |
| |
1453 |
| - | |
1454 |
| - | |
| 1453 | + | |
| 1454 | + | |
| 1455 | + | |
| 1456 | + | |
1455 | 1457 |
| |
1456 | 1458 |
| |
1457 | 1459 |
| |
|
0 commit comments
Comments
(0)