summaryrefslogtreecommitdiff
path: root/contrib
diff options
context:
space:
mode:
authorTom Lane2002-09-02 01:05:06 +0000
committerTom Lane2002-09-02 01:05:06 +0000
commitc7a165adc64e3e67e0dcee4088d84a0638b3515a (patch)
tree97d02a63e6ab6a516cb8e8ba24b0ba42782d202d /contrib
parentfcd34f9f7ff561213beef97f93c32f415e35a79c (diff)
Code review for HeapTupleHeader changes. Add version number to page headers
(overlaying low byte of page size) and add HEAP_HASOID bit to t_infomask, per earlier discussion. Simplify scheme for overlaying fields in tuple header (no need for cmax to live in more than one place). Don't try to clear infomask status bits in tqual.c --- not safe to do it there. Don't try to force output table of a SELECT INTO to have OIDs, either. Get rid of unnecessarily complex three-state scheme for TupleDesc.tdhasoids, which has already caused one recent failure. Improve documentation.
Diffstat (limited to 'contrib')
-rw-r--r--contrib/fulltextindex/fti.c2
-rw-r--r--contrib/rserv/rserv.c5
-rw-r--r--contrib/tablefunc/tablefunc.c2
3 files changed, 3 insertions, 6 deletions
diff --git a/contrib/fulltextindex/fti.c b/contrib/fulltextindex/fti.c
index 0c4cceb3f59..6c3e2fb888e 100644
--- a/contrib/fulltextindex/fti.c
+++ b/contrib/fulltextindex/fti.c
@@ -190,7 +190,7 @@ fti(PG_FUNCTION_ARGS)
tupdesc = rel->rd_att; /* what the tuple looks like (?) */
/* get oid of current tuple, needed by all, so place here */
- oid = rel->rd_rel->relhasoids ? HeapTupleGetOid(rettuple) : InvalidOid;
+ oid = HeapTupleGetOid(rettuple);
if (!OidIsValid(oid))
elog(ERROR, "Full Text Indexing: Oid of current tuple is invalid");
diff --git a/contrib/rserv/rserv.c b/contrib/rserv/rserv.c
index 8672eb79cb6..dc5f1268c97 100644
--- a/contrib/rserv/rserv.c
+++ b/contrib/rserv/rserv.c
@@ -102,10 +102,7 @@ _rserv_log_()
if (keynum == ObjectIdAttributeNumber)
{
- snprintf(oidbuf, "%u", 64,
- rel->rd_rel->relhasoids
- ? HeapTupleGetOid(tuple)
- : InvalidOid);
+ snprintf(oidbuf, "%u", sizeof(oidbuf), HeapTupleGetOid(tuple));
key = oidbuf;
}
else
diff --git a/contrib/tablefunc/tablefunc.c b/contrib/tablefunc/tablefunc.c
index 37a6e723a65..e372c4f3d67 100644
--- a/contrib/tablefunc/tablefunc.c
+++ b/contrib/tablefunc/tablefunc.c
@@ -614,7 +614,7 @@ make_crosstab_tupledesc(TupleDesc spi_tupdesc, int num_catagories)
* spi result input column.
*/
natts = num_catagories + 1;
- tupdesc = CreateTemplateTupleDesc(natts, WITHOUTOID);
+ tupdesc = CreateTemplateTupleDesc(natts, false);
/* first the rowname column */
attnum = 1;