Re: BUG #14228: replication slot catalog_xmin not cleared on slot reuse

From: Andres Freund <andres(at)anarazel(dot)de>
To: Michael Paquier <michael(dot)paquier(at)gmail(dot)com>
Cc: Andrew Gierth <andrew(at)tao11(dot)riddles(dot)org(dot)uk>, PostgreSQL mailing lists <pgsql-bugs(at)postgresql(dot)org>
Subject: Re: BUG #14228: replication slot catalog_xmin not cleared on slot reuse
Date: 2016-08-17 20:23:38
Message-ID: 20160817202338.gtdm25nq3zp4i4ul@alap3.anarazel.de
Views: Raw Message | Whole Thread | Download mbox
Thread:
Lists: pgsql-bugs

On 2016-07-28 14:22:29 +0900, Michael Paquier wrote:
> On Thu, Jul 28, 2016 at 9:24 AM, Andres Freund <andres(at)anarazel(dot)de> wrote:
> > I think it'd be better if we explicitly zeroed .data - that way the
> > likelihood of future bugs of the same ilk is smaller.
>
> Okay, I have spent some time looking at all the fields here, and their
> significance before reaching this code path in ReplicationSlotCreate,
> but did not find any hole if slot->data is zeroed. So here is an
> updated patch. You could get rid of all the field initializations I
> have done for slot->data, but I think that's cheap to keep them.

Pushed without the additional initializations - they're imo more
confusing than helpful - and with some more reordering to match the
struct order.

Regards,

Andres

In response to

Browse pgsql-bugs by date

  From Date Subject
Next Message Andres Freund 2016-08-18 00:09:32 Re: BUG #14150: Attempted to delete invisible tuple
Previous Message Magnus Hagander 2016-08-17 18:28:47 Re: BUG #14243: pg_basebackup failes by a STATUS_DELETE_PENDING file