From 9a8aeb23a19ee6833480d4c12719d9fd26ad8571 Mon Sep 17 00:00:00 2001 From: "Marc G. Fournier" Date: Mon, 2 Aug 1999 05:25:27 +0000 Subject: Another 'mega-commit' of back-patches ... - integrating the #include file cleanup that Bruce recently did - got the CPU change to adt/Makefile - changing DOUBLEALIGN -> MAXALIGN --- src/backend/access/common/heaptuple.c | 23 ++++++----------------- 1 file changed, 6 insertions(+), 17 deletions(-) (limited to 'src/backend/access/common/heaptuple.c') diff --git a/src/backend/access/common/heaptuple.c b/src/backend/access/common/heaptuple.c index 626ffd14570..1f244cc16fc 100644 --- a/src/backend/access/common/heaptuple.c +++ b/src/backend/access/common/heaptuple.c @@ -8,7 +8,7 @@ * * * IDENTIFICATION - * $Header: /cvsroot/pgsql/src/backend/access/common/heaptuple.c,v 1.53 1999/06/12 14:07:20 momjian Exp $ + * $Header: /cvsroot/pgsql/src/backend/access/common/heaptuple.c,v 1.53.2.1 1999/08/02 05:24:25 scrappy Exp $ * * NOTES * The old interface functions have been converted to macros @@ -17,21 +17,10 @@ *------------------------------------------------------------------------- */ -#include +#include "postgres.h" -#include -#include -#include -#include -#include -#include -#include - -#ifndef HAVE_MEMMOVE -#include -#else -#include -#endif +#include "access/heapam.h" +#include "catalog/pg_type.h" /* Used by heap_getattr() macro, for speed */ long heap_sysoffset[] = { @@ -688,7 +677,7 @@ heap_formtuple(TupleDesc tupleDescriptor, len += bitmaplen; } - hoff = len = DOUBLEALIGN(len); /* be conservative here */ + hoff = len = MAXALIGN(len); /* be conservative here */ len += ComputeDataSize(tupleDescriptor, value, nulls); @@ -822,7 +811,7 @@ heap_addheader(uint32 natts, /* max domain index */ len = offsetof(HeapTupleHeaderData, t_bits); - hoff = len = DOUBLEALIGN(len); /* be conservative */ + hoff = len = MAXALIGN(len); /* be conservative */ len += structlen; tuple = (HeapTuple) palloc(HEAPTUPLESIZE + len); td = tuple->t_data = (HeapTupleHeader) ((char *) tuple + HEAPTUPLESIZE); -- cgit v1.2.3