| From: | Markos Fountoulakis <markos(at)planetscale(dot)com> |
|---|---|
| To: | PostgreSQL Hackers <pgsql-hackers(at)lists(dot)postgresql(dot)org> |
| Subject: | [PATCH] Fix argument in pg_indexam_progress_phasename() |
| Date: | 2026-10-21 14:15:56 |
| Message-ID: | e791bbb7-af3a-4a91-a5bb-c744e5c3ef54@planetscale.com |
| Views: | Whole Thread | Raw Message | Download mbox | Resend email |
| Thread: | |
| Lists: | pgsql-hackers |
Hello,
There is a oversight in pg_indexam_progress_phasename() since ab0dfc961b6 where the second argument is declared int8 in pg_proc.dat but gotten via PG_GETARG_INT32() in the C code.
This isn't much of a problem since 2a600a93c7b where Datums became 8 byte wide everywhere. However, this is an actual problem in 32-bit architecture in older PostgreSQL versions where int8 is passed by reference and returns bogus numbers. The side effect is that pg_stat_progress_create_index never shows the access method phasename. This should probably be backpatched.
--
Markos Fountoulakis
PlanetScale Postgres Core Team
| Attachment | Content-Type | Size |
|---|---|---|
| v1-0001-Fix-argument-in-pg_indexam_progress_phasename.patch | text/plain | 956 bytes |
| From | Date | Subject | |
|---|---|---|---|
| Next Message | Ayush Tiwari | 2026-10-21 14:21:01 | Re: [DEPARSE] EXPLAIN prints another ModifyTable's RETURNING aliases in a SubPlan |
| Previous Message | Jim Jones | 2026-10-21 14:03:45 | Re: [PATCH] Add CANONICAL option to xmlserialize |