From: | jian he <jian(dot)universality(at)gmail(dot)com> |
---|---|
To: | pgsql-hackers(at)postgresql(dot)org |
Subject: | call ATPostAlterTypeParse inconsistency |
Date: | 2024-04-15 00:00:00 |
Message-ID: | CACJufxGk8nBdamJFatbPawu9jqeqTz+wWgCG0YQMm+HW-dJcDg@mail.gmail.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
hi.
one minor issue.
within ATPostAlterTypeCleanup, we call ATPostAlterTypeParse:
ATPostAlterTypeParse(oldId, relid, InvalidOid,
(char *) lfirst(def_item),
wqueue, lockmode, tab->rewrite);
function ATPostAlterTypeParse is:
static void
ATPostAlterTypeParse(Oid oldId, Oid oldRelId, Oid refRelId, char *cmd,
List **wqueue, LOCKMODE lockmode, bool rewrite)
but tab->rewrite is an int.
so within ATPostAlterTypeCleanup we should call it like:
ATPostAlterTypeParse(oldId, relid, InvalidOid,
(char *) lfirst(def_item),
wqueue, lockmode, tab->rewrite != 0);
or
ATPostAlterTypeParse(oldId, relid, InvalidOid,
(char *) lfirst(def_item),
wqueue, lockmode, tab->rewrite > 0);
From | Date | Subject | |
---|---|---|---|
Next Message | Michael Paquier | 2024-04-15 00:04:07 | Re: Stability of queryid in minor versions |
Previous Message | Tom Lane | 2024-04-14 23:54:28 | Re: Fix out-of-bounds in the function GetCommandTagName |