1
0
mirror of https://github.com/postgres/postgres.git synced 2025-11-10 17:42:29 +03:00

Ye-old pgindent run. Same 4-space tabs.

This commit is contained in:
Bruce Momjian
2000-04-12 17:17:23 +00:00
parent db4518729d
commit 52f77df613
434 changed files with 24799 additions and 21246 deletions

View File

@@ -9,7 +9,7 @@
*
*
* IDENTIFICATION
* $Header: /cvsroot/pgsql/src/backend/access/common/heaptuple.c,v 1.61 2000/01/26 05:55:53 momjian Exp $
* $Header: /cvsroot/pgsql/src/backend/access/common/heaptuple.c,v 1.62 2000/04/12 17:14:36 momjian Exp $
*
* NOTES
* The old interface functions have been converted to macros
@@ -137,9 +137,9 @@ DataFill(char *data,
*((int32 *) value[i]));
break;
default:
Assert(att[i]->attlen >= 0);
memmove(data, DatumGetPointer(value[i]),
(size_t)(att[i]->attlen));
Assert(att[i]->attlen >= 0);
memmove(data, DatumGetPointer(value[i]),
(size_t) (att[i]->attlen));
break;
}
data = (char *) att_addlength((long) data, att[i]->attlen, value[i]);
@@ -326,7 +326,7 @@ nocachegetattr(HeapTuple tuple,
Form_pg_attribute *att = tupleDesc->attrs;
int slow = 0; /* do we have to walk nulls? */
(void)isnull; /*not used*/
(void) isnull; /* not used */
#ifdef IN_MACRO
/* This is handled in the macro */
Assert(attnum > 0);
@@ -681,7 +681,7 @@ heap_formtuple(TupleDesc tupleDescriptor,
len += bitmaplen;
}
hoff = len = MAXALIGN(len); /* be conservative here */
hoff = len = MAXALIGN(len); /* be conservative here */
len += ComputeDataSize(tupleDescriptor, value, nulls);
@@ -806,11 +806,9 @@ void
heap_freetuple(HeapTuple htup)
{
if (htup->t_data != NULL)
if (htup->t_datamcxt != NULL && (char *)(htup->t_data) !=
((char *) htup + HEAPTUPLESIZE))
{
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);
}
@@ -835,7 +833,7 @@ heap_addheader(uint32 natts, /* max domain index */
len = offsetof(HeapTupleHeaderData, t_bits);
hoff = len = MAXALIGN(len); /* be conservative */
hoff = len = MAXALIGN(len); /* be conservative */
len += structlen;
tuple = (HeapTuple) palloc(HEAPTUPLESIZE + len);
tuple->t_datamcxt = CurrentMemoryContext;
@@ -850,8 +848,8 @@ heap_addheader(uint32 natts, /* max domain index */
td->t_infomask = 0;
td->t_infomask |= HEAP_XMAX_INVALID;
if (structlen > 0)
memmove((char *) td + hoff, structure, (size_t)structlen);
if (structlen > 0)
memmove((char *) td + hoff, structure, (size_t) structlen);
return tuple;
}

View File

@@ -9,7 +9,7 @@
*
*
* IDENTIFICATION
* $Header: /cvsroot/pgsql/src/backend/access/common/indextuple.c,v 1.42 2000/01/26 05:55:53 momjian Exp $
* $Header: /cvsroot/pgsql/src/backend/access/common/indextuple.c,v 1.43 2000/04/12 17:14:37 momjian Exp $
*
*-------------------------------------------------------------------------
*/
@@ -60,7 +60,7 @@ index_formtuple(TupleDesc tupleDescriptor,
hoff = IndexInfoFindDataOffset(infomask);
size = hoff + ComputeDataSize(tupleDescriptor, value, null);
size = MAXALIGN(size); /* be conservative */
size = MAXALIGN(size); /* be conservative */
tp = (char *) palloc(size);
tuple = (IndexTuple) tp;
@@ -134,7 +134,7 @@ nocache_index_getattr(IndexTuple tup,
int data_off; /* tuple data offset */
Form_pg_attribute *att = tupleDesc->attrs;
(void)isnull;
(void) isnull;
/* ----------------
* sanity checks
* ----------------

View File

@@ -8,7 +8,7 @@
*
*
* IDENTIFICATION
* $Header: /cvsroot/pgsql/src/backend/access/common/tupdesc.c,v 1.61 2000/01/31 04:35:48 tgl Exp $
* $Header: /cvsroot/pgsql/src/backend/access/common/tupdesc.c,v 1.62 2000/04/12 17:14:37 momjian Exp $
*
* NOTES
* some of the executor utility code such as "ExecTypeFromTL" should be
@@ -229,17 +229,19 @@ FreeTupleDesc(TupleDesc tupdesc)
bool
equalTupleDescs(TupleDesc tupdesc1, TupleDesc tupdesc2)
{
int i;
int i;
if (tupdesc1->natts != tupdesc2->natts)
return false;
for (i = 0; i < tupdesc1->natts; i++)
{
Form_pg_attribute attr1 = tupdesc1->attrs[i];
Form_pg_attribute attr2 = tupdesc2->attrs[i];
Form_pg_attribute attr1 = tupdesc1->attrs[i];
Form_pg_attribute attr2 = tupdesc2->attrs[i];
/* We do not need to check every single field here, and in fact
* some fields such as attdisbursion probably shouldn't be compared.
/*
* We do not need to check every single field here, and in fact
* some fields such as attdisbursion probably shouldn't be
* compared.
*/
if (strcmp(NameStr(attr1->attname), NameStr(attr2->attname)) != 0)
return false;
@@ -254,8 +256,8 @@ equalTupleDescs(TupleDesc tupdesc1, TupleDesc tupdesc2)
}
if (tupdesc1->constr != NULL)
{
TupleConstr *constr1 = tupdesc1->constr;
TupleConstr *constr2 = tupdesc2->constr;
TupleConstr *constr1 = tupdesc1->constr;
TupleConstr *constr2 = tupdesc2->constr;
if (constr2 == NULL)
return false;
@@ -263,8 +265,8 @@ equalTupleDescs(TupleDesc tupdesc1, TupleDesc tupdesc2)
return false;
for (i = 0; i < (int) constr1->num_defval; i++)
{
AttrDefault *defval1 = constr1->defval + i;
AttrDefault *defval2 = constr2->defval + i;
AttrDefault *defval1 = constr1->defval + i;
AttrDefault *defval2 = constr2->defval + i;
if (defval1->adnum != defval2->adnum)
return false;
@@ -275,8 +277,8 @@ equalTupleDescs(TupleDesc tupdesc1, TupleDesc tupdesc2)
return false;
for (i = 0; i < (int) constr1->num_check; i++)
{
ConstrCheck *check1 = constr1->check + i;
ConstrCheck *check2 = constr2->check + i;
ConstrCheck *check1 = constr1->check + i;
ConstrCheck *check2 = constr2->check + i;
if (strcmp(check1->ccname, check2->ccname) != 0)
return false;
@@ -585,8 +587,9 @@ BuildDescForRelation(List *schema, char *relname)
constr->has_not_null = true;
desc->attrs[attnum - 1]->attnotnull = entry->is_not_null;
/* Note we copy only pre-cooked default expressions.
* Digestion of raw ones is someone else's problem.
/*
* Note we copy only pre-cooked default expressions. Digestion of
* raw ones is someone else's problem.
*/
if (entry->cooked_default != NULL)
{