The following bug has been logged on the website:
Bug reference: 14985
Logged by: bucoo hsiao
Email address: bucoo@sohu.com
PostgreSQL version: 10.1
Operating system: all
Description:
HeapTuple
ExecCopySlotTuple(TupleTableSlot *slot)
{
/*
* sanity checks
*/
Assert(slot != NULL);
Assert(!slot->tts_isempty);
/*
* If we have a physical tuple (either format) then just copy it.
*/
if (TTS_HAS_PHYSICAL_TUPLE(slot))
return heap_copytuple(slot->tts_tuple);
if (slot->tts_mintuple)
return heap_tuple_from_minimal_tuple(slot->tts_mintuple);
/* should be:
if (slot->tts_mintuple)
{
HeapTuple result =
heap_tuple_from_minimal_tuple(slot->tts_mintuple);
HeapTupleHeaderSetTypeId(result->t_data,
slot->tts_tupleDescriptor->tdtypeid);
HeapTupleHeaderSetTypMod(result->t_data,
slot->tts_tupleDescriptor->tdtypmod);
return result;
}
*/
...
}