Re: BUG #14208: Inconsistent code modification - 3

From: Andres Freund <andres(at)anarazel(dot)de>
To: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
Cc: petrum(at)gmail(dot)com, pgsql-bugs(at)postgresql(dot)org
Subject: Re: BUG #14208: Inconsistent code modification - 3
Date: 2016-06-30 16:47:12
Message-ID: 20160630164712.xliqfdkrb63tumny@alap3.anarazel.de
Views: Whole Thread | Raw Message | Download mbox | Resend email
Thread:
Lists: pgsql-bugs

On 2016-06-30 12:40:19 -0400, Tom Lane wrote:
> Andres Freund <andres(at)anarazel(dot)de> writes:
> > On 2016-06-22 11:45:16 -0400, Tom Lane wrote:
> >> Actually, the function is ReorderBufferIterTXNInit, and in HEAD this
> >> is line 963, but yeah that looks pretty broken. Andres, do you
> >> concur?
>
> > Ugh, yes, that looks broken. In a way that can very likely lead to wrong
> > data being returned :(. I assume an empty toplevel transaction +
> > subtransactions with spilled-to-disk contents will be bad.
>
> Actually, doesn't this mean spilled subtransactions will *always* be lost?
> Whether or not the toplevel transaction is empty, by the time we get here
> it would have nentries == nentries_mem, no?

Not, if the top-level transaction spilled to disk.

> Anyway, fix pushed.

Thanks!.

> I did not try to devise a regression test case.

I'll try to add some.

Andres

In response to

Responses

Browse pgsql-bugs by date

  From Date Subject
Next Message Tom Lane 2016-06-30 16:51:51 Re: BUG #14208: Inconsistent code modification - 3
Previous Message Tom Lane 2016-06-30 16:40:19 Re: BUG #14208: Inconsistent code modification - 3