From: | Amit Kapila <amit(dot)kapila16(at)gmail(dot)com> |
---|---|
To: | vignesh C <vignesh21(at)gmail(dot)com> |
Cc: | Peter Smith <smithpb2250(at)gmail(dot)com>, PostgreSQL Hackers <pgsql-hackers(at)lists(dot)postgresql(dot)org> |
Subject: | Re: Add macros for ReorderBufferTXN toptxn |
Date: | 2023-03-14 11:46:50 |
Message-ID: | CAA4eK1+oqfUSC3vpu6bJzgfnSmu_yaeoLS=Rb3416GuS5iRP1Q@mail.gmail.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
On Tue, Mar 14, 2023 at 5:03 PM vignesh C <vignesh21(at)gmail(dot)com> wrote:
>
> On Tue, 14 Mar 2023 at 12:37, Peter Smith <smithpb2250(at)gmail(dot)com> wrote:
> >
>
> The same issue exists here too:
> 1)
> - if (toptxn != NULL && !rbtxn_has_catalog_changes(toptxn))
> + if (rbtxn_is_subtxn(txn))
> {
> - toptxn->txn_flags |= RBTXN_HAS_CATALOG_CHANGES;
> - dclist_push_tail(&rb->catchange_txns, &toptxn->catchange_node);
> + ReorderBufferTXN *toptxn = rbtxn_get_toptxn(txn);
>
> 2)
> - if (change->txn->toptxn)
> - topxid = change->txn->toptxn->xid;
> + if (rbtxn_is_subtxn(change->txn))
> + topxid = rbtxn_get_toptxn(change->txn)->xid;
>
> If you plan to fix, bothe the above also should be handled.
>
I don't know if it would be any better to change the above two as
compared to what the proposed patch has.
--
With Regards,
Amit Kapila.
From | Date | Subject | |
---|---|---|---|
Next Message | Juan José Santamaría Flecha | 2023-03-14 12:26:27 | Fix fseek() detection of unseekable files on WIN32 |
Previous Message | Amit Kapila | 2023-03-14 11:43:18 | Re: Add macros for ReorderBufferTXN toptxn |