修复drop netst table of type后再创建同名domain,创建pacakge使用该字段coredump的问题。

This commit is contained in:
dongxu.wei
2022-09-13 09:40:33 +08:00
parent dcfa44b9fb
commit ab3d6c1bb1

View File

@ -9520,6 +9520,12 @@ static void check_record_nest_tableof_index(PLpgSQL_datum* datum)
PLpgSQL_row* row = (PLpgSQL_row*)datum;
for (int i = 0; i < row->nfields; i++) {
PLpgSQL_datum* row_element = NULL;
/* check wether attisdropped */
if (row->varnos[i] == -1 && row->fieldnames[i] == NULL) {
continue;
}
if (row->ispkg) {
row_element = (PLpgSQL_datum*)(row->pkg->datums[row->varnos[i]]);
} else {