[BUG] pg9.4.10 Logical decoding did not get the correct oldtuplelen

From: anderson <anderson2013(at)qq(dot)com>
To: pgsql-bugs <pgsql-bugs(at)postgresql(dot)org>
Subject: [BUG] pg9.4.10 Logical decoding did not get the correct oldtuplelen
Date: 2016-12-27 03:30:47
Message-ID: tencent_5B4204547B0BB8C05F9B1D99@qq.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-bugs

hi team:

I found a postgresql 9.4.10 Logical decoding problem
heapam.c:6976 xlog store incorrect oldtuplen when tuplelen is greater than the value field of uint16.

a uint32 variable is assigned to uint16

The structure that holds the oldkey length is:
typedef struct xl_heap_header_len
{
uint16 t_len;
xl_heap_header header;
} xl_heap_header_len;

The problem will lead to logic decoding failure when oldtuplene > 65535 and relreplident = FULL.
The table that triggers the problem is usually relreplident = FULL.

Responses

Browse pgsql-bugs by date

  From Date Subject
Next Message Michael Paquier 2016-12-27 05:29:44 Re: [BUG] pg9.4.10 Logical decoding did not get the correct oldtuplelen
Previous Message Michael Paquier 2016-12-27 03:10:35 pg_receivexlog creating holes in WAL (HEAD only)