summaryrefslogtreecommitdiff
path: root/src/backend/commands/prepare.c
diff options
context:
space:
mode:
authorDavid Rowley <drowley@postgresql.org>2024-07-02 13:41:47 +1200
committerDavid Rowley <drowley@postgresql.org>2024-07-02 13:41:47 +1200
commit65b71dec2d577e9ef7423773a88fdd075f3eb97f (patch)
tree29eb2dbbbb577b2c2ad64b4a21fdc0f660aa5347 /src/backend/commands/prepare.c
parent0c1aca461481216ff5a0e65538c4880bcf346433 (diff)
Use TupleDescAttr macro consistently
A few places were directly accessing the attrs[] array. This goes against the standards set by 2cd708452. Fix that. Discussion: https://postgr.es/m/CAApHDvrBztXP3yx=NKNmo3xwFAFhEdyPnvrDg3=M0RhDs+4vYw@mail.gmail.com
Diffstat (limited to 'src/backend/commands/prepare.c')
-rw-r--r--src/backend/commands/prepare.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/backend/commands/prepare.c b/src/backend/commands/prepare.c
index 5e85585e9dd..07257d4db94 100644
--- a/src/backend/commands/prepare.c
+++ b/src/backend/commands/prepare.c
@@ -717,7 +717,7 @@ pg_prepared_statement(PG_FUNCTION_ARGS)
result_types = palloc_array(Oid, result_desc->natts);
for (int i = 0; i < result_desc->natts; i++)
- result_types[i] = result_desc->attrs[i].atttypid;
+ result_types[i] = TupleDescAttr(result_desc, i)->atttypid;
values[4] = build_regtype_array(result_types, result_desc->natts);
}
else