diff options
Diffstat (limited to 'contrib')
| -rw-r--r-- | contrib/dbsize/dbsize.c | 2 | ||||
| -rw-r--r-- | contrib/fulltextindex/fti.c | 2 | ||||
| -rw-r--r-- | contrib/rserv/rserv.c | 4 |
3 files changed, 5 insertions, 3 deletions
diff --git a/contrib/dbsize/dbsize.c b/contrib/dbsize/dbsize.c index b072a86912f..44699aa6936 100644 --- a/contrib/dbsize/dbsize.c +++ b/contrib/dbsize/dbsize.c @@ -65,7 +65,7 @@ database_size(PG_FUNCTION_ARGS) if (!HeapTupleIsValid(tuple)) elog(ERROR, "database %s does not exist", NameStr(*dbname)); - dbid = tuple->t_data->t_oid; + dbid = HeapTupleGetOid(tuple); if (dbid == InvalidOid) elog(ERROR, "invalid database id"); diff --git a/contrib/fulltextindex/fti.c b/contrib/fulltextindex/fti.c index aabb2caf9f9..8050f2a9d72 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 = rettuple->t_data->t_oid; + oid = rel->rd_rel->relhasoids ? HeapTupleGetOid(rettuple) : InvalidOid; 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 401cc5fd9cc..54da14a6961 100644 --- a/contrib/rserv/rserv.c +++ b/contrib/rserv/rserv.c @@ -102,7 +102,9 @@ _rserv_log_() if (keynum == ObjectIdAttributeNumber) { - sprintf(oidbuf, "%u", tuple->t_data->t_oid); + sprintf(oidbuf, "%u", rel->rd_rel->relhasoids + ? HeapTupleGetOid(tuple) + : InvalidOid); key = oidbuf; } else |
