mirror of
https://github.com/postgres/postgres.git
synced 2025-04-27 22:56:53 +03:00
Assert that pre/post-fix updated tuples are on the same page during replay.
If they were not 'oldtup.t_data' would be dereferenced while set to NULL in case of a full page image for block 0. Do so primarily to silence coverity; but also to make sure this prerequisite isn't changed without adapting the replay routine as that would appear to work in many cases. Andres Freund
This commit is contained in:
parent
a692ee5870
commit
1460b199e6
@ -8115,11 +8115,13 @@ newsame:;
|
||||
|
||||
if (xlrec->flags & XLOG_HEAP_PREFIX_FROM_OLD)
|
||||
{
|
||||
Assert(samepage);
|
||||
memcpy(&prefixlen, recdata, sizeof(uint16));
|
||||
recdata += sizeof(uint16);
|
||||
}
|
||||
if (xlrec->flags & XLOG_HEAP_SUFFIX_FROM_OLD)
|
||||
{
|
||||
Assert(samepage);
|
||||
memcpy(&suffixlen, recdata, sizeof(uint16));
|
||||
recdata += sizeof(uint16);
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user