Fix incorrect comment in pgstat_backend.c
authorMichael Paquier <[email protected]>
Wed, 3 Sep 2025 23:34:57 +0000 (08:34 +0900)
committerMichael Paquier <[email protected]>
Wed, 3 Sep 2025 23:34:57 +0000 (08:34 +0900)
commitc91c61b2417d0c36993deff03f09b1f64c821a1b
tree1a9cc33a41fbc2a3ec4973bcbb9e2daf9b4f4f16
parentab4a35b4ea9d2290b1ee5ec25f65df4c739077cb
Fix incorrect comment in pgstat_backend.c

The counters saved from pgWalUsage, used for the difference calculations
when flushing the backend WAL stats, are updated when calling
pgstat_flush_backend() under PGSTAT_BACKEND_FLUSH_WAL, and not
pgstat_report_wal().  The comment updated in this commit referenced the
latter, but it is perfectly OK to flush the backend stats independently
of the WAL stats.

Noticed while looking at this area of the code, introduced by
76def4cdd7c2 as a copy-pasto.

Backpatch-through: 18
src/backend/utils/activity/pgstat_backend.c