pg.ddx.io  pgsql-committers@postgresql.org mailing list archive  
help / color / mirror / Atom feed
pgsql: Fix pg_stat_get_backend_activity() to use multi-byte truncated r
6+ messages / 1 participants
[nested] [flat]

* pgsql: Fix pg_stat_get_backend_activity() to use multi-byte truncated r
@ 2025-12-27 08:24  Michael Paquier <michael@paquier.xyz>
  0 siblings, 0 replies; 6+ messages in thread

From: Michael Paquier @ 2025-12-27 08:24 UTC (permalink / raw)
  To: pgsql-committers@lists.postgresql.org

Fix pg_stat_get_backend_activity() to use multi-byte truncated result

pg_stat_get_backend_activity() calls pgstat_clip_activity() to ensure
that the reported query string is correctly truncated when it finishes
with an incomplete multi-byte sequence.  However, the result returned by
the function was not what pgstat_clip_activity() generated, but the
non-truncated, original, contents from PgBackendStatus.st_activity_raw.

Oversight in 54b6cd589ac2, so backpatch all the way down.

Author: Chao Li <li.evan.chao@gmail.com>
Discussion: https://postgr.es/m/CAEoWx2mDzwc48q2EK9tSXS6iJMJ35wvxNQnHX+rXjy5VgLvJQw@mail.gmail.com
Backpatch-through: 14

Branch
------
master

Details
-------
https://git.postgresql.org/pg/commitdiff/36b8f4974a884a7206df97f37ea62d2adc0b77f0

Modified Files
--------------
src/backend/utils/adt/pgstatfuncs.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)



^ permalink  raw  reply  [nested|flat] 6+ messages in thread

* pgsql: Fix pg_stat_get_backend_activity() to use multi-byte truncated r
@ 2025-12-27 08:24  Michael Paquier <michael@paquier.xyz>
  0 siblings, 0 replies; 6+ messages in thread

From: Michael Paquier @ 2025-12-27 08:24 UTC (permalink / raw)
  To: pgsql-committers@lists.postgresql.org

Fix pg_stat_get_backend_activity() to use multi-byte truncated result

pg_stat_get_backend_activity() calls pgstat_clip_activity() to ensure
that the reported query string is correctly truncated when it finishes
with an incomplete multi-byte sequence.  However, the result returned by
the function was not what pgstat_clip_activity() generated, but the
non-truncated, original, contents from PgBackendStatus.st_activity_raw.

Oversight in 54b6cd589ac2, so backpatch all the way down.

Author: Chao Li <li.evan.chao@gmail.com>
Discussion: https://postgr.es/m/CAEoWx2mDzwc48q2EK9tSXS6iJMJ35wvxNQnHX+rXjy5VgLvJQw@mail.gmail.com
Backpatch-through: 14

Branch
------
REL_17_STABLE

Details
-------
https://git.postgresql.org/pg/commitdiff/52b27f5859f6bf747fbb8275302fac962b645312

Modified Files
--------------
src/backend/utils/adt/pgstatfuncs.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)



^ permalink  raw  reply  [nested|flat] 6+ messages in thread

* pgsql: Fix pg_stat_get_backend_activity() to use multi-byte truncated r
@ 2025-12-27 08:24  Michael Paquier <michael@paquier.xyz>
  0 siblings, 0 replies; 6+ messages in thread

From: Michael Paquier @ 2025-12-27 08:24 UTC (permalink / raw)
  To: pgsql-committers@lists.postgresql.org

Fix pg_stat_get_backend_activity() to use multi-byte truncated result

pg_stat_get_backend_activity() calls pgstat_clip_activity() to ensure
that the reported query string is correctly truncated when it finishes
with an incomplete multi-byte sequence.  However, the result returned by
the function was not what pgstat_clip_activity() generated, but the
non-truncated, original, contents from PgBackendStatus.st_activity_raw.

Oversight in 54b6cd589ac2, so backpatch all the way down.

Author: Chao Li <li.evan.chao@gmail.com>
Discussion: https://postgr.es/m/CAEoWx2mDzwc48q2EK9tSXS6iJMJ35wvxNQnHX+rXjy5VgLvJQw@mail.gmail.com
Backpatch-through: 14

Branch
------
REL_18_STABLE

Details
-------
https://git.postgresql.org/pg/commitdiff/06907e864733ed02056e510c3f405414335bcae3

Modified Files
--------------
src/backend/utils/adt/pgstatfuncs.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)



^ permalink  raw  reply  [nested|flat] 6+ messages in thread

* pgsql: Fix pg_stat_get_backend_activity() to use multi-byte truncated r
@ 2025-12-27 08:24  Michael Paquier <michael@paquier.xyz>
  0 siblings, 0 replies; 6+ messages in thread

From: Michael Paquier @ 2025-12-27 08:24 UTC (permalink / raw)
  To: pgsql-committers@lists.postgresql.org

Fix pg_stat_get_backend_activity() to use multi-byte truncated result

pg_stat_get_backend_activity() calls pgstat_clip_activity() to ensure
that the reported query string is correctly truncated when it finishes
with an incomplete multi-byte sequence.  However, the result returned by
the function was not what pgstat_clip_activity() generated, but the
non-truncated, original, contents from PgBackendStatus.st_activity_raw.

Oversight in 54b6cd589ac2, so backpatch all the way down.

Author: Chao Li <li.evan.chao@gmail.com>
Discussion: https://postgr.es/m/CAEoWx2mDzwc48q2EK9tSXS6iJMJ35wvxNQnHX+rXjy5VgLvJQw@mail.gmail.com
Backpatch-through: 14

Branch
------
REL_16_STABLE

Details
-------
https://git.postgresql.org/pg/commitdiff/c48829ed8308e9e1767e5ce4d883996348af5b68

Modified Files
--------------
src/backend/utils/adt/pgstatfuncs.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)



^ permalink  raw  reply  [nested|flat] 6+ messages in thread

* pgsql: Fix pg_stat_get_backend_activity() to use multi-byte truncated r
@ 2025-12-27 08:24  Michael Paquier <michael@paquier.xyz>
  0 siblings, 0 replies; 6+ messages in thread

From: Michael Paquier @ 2025-12-27 08:24 UTC (permalink / raw)
  To: pgsql-committers@lists.postgresql.org

Fix pg_stat_get_backend_activity() to use multi-byte truncated result

pg_stat_get_backend_activity() calls pgstat_clip_activity() to ensure
that the reported query string is correctly truncated when it finishes
with an incomplete multi-byte sequence.  However, the result returned by
the function was not what pgstat_clip_activity() generated, but the
non-truncated, original, contents from PgBackendStatus.st_activity_raw.

Oversight in 54b6cd589ac2, so backpatch all the way down.

Author: Chao Li <li.evan.chao@gmail.com>
Discussion: https://postgr.es/m/CAEoWx2mDzwc48q2EK9tSXS6iJMJ35wvxNQnHX+rXjy5VgLvJQw@mail.gmail.com
Backpatch-through: 14

Branch
------
REL_15_STABLE

Details
-------
https://git.postgresql.org/pg/commitdiff/300575fe2e7f0f75bec92682cd9122a72998fd04

Modified Files
--------------
src/backend/utils/adt/pgstatfuncs.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)



^ permalink  raw  reply  [nested|flat] 6+ messages in thread

* pgsql: Fix pg_stat_get_backend_activity() to use multi-byte truncated r
@ 2025-12-27 08:24  Michael Paquier <michael@paquier.xyz>
  0 siblings, 0 replies; 6+ messages in thread

From: Michael Paquier @ 2025-12-27 08:24 UTC (permalink / raw)
  To: pgsql-committers@lists.postgresql.org

Fix pg_stat_get_backend_activity() to use multi-byte truncated result

pg_stat_get_backend_activity() calls pgstat_clip_activity() to ensure
that the reported query string is correctly truncated when it finishes
with an incomplete multi-byte sequence.  However, the result returned by
the function was not what pgstat_clip_activity() generated, but the
non-truncated, original, contents from PgBackendStatus.st_activity_raw.

Oversight in 54b6cd589ac2, so backpatch all the way down.

Author: Chao Li <li.evan.chao@gmail.com>
Discussion: https://postgr.es/m/CAEoWx2mDzwc48q2EK9tSXS6iJMJ35wvxNQnHX+rXjy5VgLvJQw@mail.gmail.com
Backpatch-through: 14

Branch
------
REL_14_STABLE

Details
-------
https://git.postgresql.org/pg/commitdiff/ea3524cffa81386aadb7eb8245d05a2ce2f71562

Modified Files
--------------
src/backend/utils/adt/pgstatfuncs.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)



^ permalink  raw  reply  [nested|flat] 6+ messages in thread


end of thread, other threads:[~2025-12-27 08:24 UTC | newest]

Thread overview: 6+ messages (download: mbox mbox.gz follow: Atom feed)
-- links below jump to the message on this page --
2025-12-27 08:24 pgsql: Fix pg_stat_get_backend_activity() to use multi-byte truncated r Michael Paquier <michael@paquier.xyz>
2025-12-27 08:24 pgsql: Fix pg_stat_get_backend_activity() to use multi-byte truncated r Michael Paquier <michael@paquier.xyz>
2025-12-27 08:24 pgsql: Fix pg_stat_get_backend_activity() to use multi-byte truncated r Michael Paquier <michael@paquier.xyz>
2025-12-27 08:24 pgsql: Fix pg_stat_get_backend_activity() to use multi-byte truncated r Michael Paquier <michael@paquier.xyz>
2025-12-27 08:24 pgsql: Fix pg_stat_get_backend_activity() to use multi-byte truncated r Michael Paquier <michael@paquier.xyz>
2025-12-27 08:24 pgsql: Fix pg_stat_get_backend_activity() to use multi-byte truncated r Michael Paquier <michael@paquier.xyz>

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox