aboutsummaryrefslogtreecommitdiff
path: root/src/backend/access/common
diff options
context:
space:
mode:
Diffstat (limited to 'src/backend/access/common')
-rw-r--r--src/backend/access/common/heaptuple.c10
-rw-r--r--src/backend/access/common/tupdesc.c13
2 files changed, 10 insertions, 13 deletions
diff --git a/src/backend/access/common/heaptuple.c b/src/backend/access/common/heaptuple.c
index f93bf34db90..319cfff7ca3 100644
--- a/src/backend/access/common/heaptuple.c
+++ b/src/backend/access/common/heaptuple.c
@@ -9,7 +9,7 @@
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/access/common/heaptuple.c,v 1.63 2000/07/02 22:00:24 momjian Exp $
+ * $Header: /cvsroot/pgsql/src/backend/access/common/heaptuple.c,v 1.64 2000/07/03 23:09:10 wieck Exp $
*
* NOTES
* The old interface functions have been converted to macros
@@ -119,7 +119,11 @@ DataFill(char *data,
{
case -1:
*infomask |= HEAP_HASVARLENA;
- data_length = VARSIZE(DatumGetPointer(value[i]));
+ if (VARATT_IS_EXTERNAL(value[i]))
+ *infomask |= HEAP_HASEXTERNAL;
+ if (VARATT_IS_COMPRESSED(value[i]))
+ *infomask |= HEAP_HASCOMPRESSED;
+ data_length = VARATT_SIZE(DatumGetPointer(value[i]));
memmove(data, DatumGetPointer(value[i]), data_length);
break;
case sizeof(char):
@@ -816,7 +820,7 @@ heap_freetuple(HeapTuple htup)
if (htup->t_data != NULL)
if (htup->t_datamcxt != NULL && (char *) (htup->t_data) !=
((char *) htup + HEAPTUPLESIZE))
- elog(NOTICE, "TELL Jan Wieck: heap_freetuple() found separate t_data");
+ pfree(htup->t_data);
pfree(htup);
}
diff --git a/src/backend/access/common/tupdesc.c b/src/backend/access/common/tupdesc.c
index 433bbe6b06b..c878c50e0af 100644
--- a/src/backend/access/common/tupdesc.c
+++ b/src/backend/access/common/tupdesc.c
@@ -8,7 +8,7 @@
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/access/common/tupdesc.c,v 1.65 2000/05/30 00:49:38 momjian Exp $
+ * $Header: /cvsroot/pgsql/src/backend/access/common/tupdesc.c,v 1.66 2000/07/03 23:09:10 wieck Exp $
*
* NOTES
* some of the executor utility code such as "ExecTypeFromTL" should be
@@ -434,23 +434,16 @@ TupleDescInitEntry(TupleDesc desc,
att->attlen = typeLen(t);
att->attbyval = typeByVal(t);
- att->attstorage = 'p';
}
else
{
att->attlen = typeForm->typlen;
att->attbyval = typeForm->typbyval;
/*
- * This will enable ALL variable size attributes of user
- * relations for automatic move off into "secondary" relation.
- * Jan
+ * Default to the types storage
*/
#ifdef TUPLE_TOASTER_ACTIVE
-#ifdef TUPLE_TOASTER_ALL_TYPES
- att->attstorage = (att->attlen == -1) ? 'e' : 'p';
-#else
- att->attstorage = 'p';
-#endif
+ att->attstorage = typeForm->typstorage;
#else
att->attstorage = 'p';
#endif