Hi Alvaro, > There are three makeNode(ResultRelInfo), but they don't look anything > out of the ordinary: > [...] > src/ts_catalog/catalog.c-extern TSDLLEXPORT ResultRelInfo * > src/ts_catalog/catalog.c-ts_catalog_open_indexes(Relation heapRel) > src/ts_catalog/catalog.c-{ > src/ts_catalog/catalog.c- ResultRelInfo *resultRelInfo; > src/ts_catalog/catalog.c- > src/ts_catalog/catalog.c: resultRelInfo = makeNode(ResultRelInfo); > src/ts_catalog/catalog.c- resultRelInfo->ri_RangeTableIndex = 0; /* dummy */ > src/ts_catalog/catalog.c- resultRelInfo->ri_RelationDesc = heapRel; > src/ts_catalog/catalog.c- resultRelInfo->ri_TrigDesc = NULL; /* we don't > fire triggers */ > src/ts_catalog/catalog.c- > src/ts_catalog/catalog.c- ExecOpenIndices(resultRelInfo, false);
ExecOpenIndices() will not fill the ri_needLockTagTuple field for the caller and it will contain garbage. Since you assumed this is the correct usage, maybe it should? -- Best regards, Aleksander Alekseev