1
0
mirror of https://github.com/postgres/postgres.git synced 2025-08-09 17:03:00 +03:00

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
This commit is contained in:
Marc G. Fournier
1999-08-02 05:25:27 +00:00
parent 62d146bdcd
commit 9a8aeb23a1
142 changed files with 472 additions and 1048 deletions

View File

@@ -8,7 +8,7 @@
* *
* *
* IDENTIFICATION * 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 * NOTES
* The old interface functions have been converted to macros * The old interface functions have been converted to macros
@@ -17,21 +17,10 @@
*------------------------------------------------------------------------- *-------------------------------------------------------------------------
*/ */
#include <postgres.h> #include "postgres.h"
#include <access/heapam.h> #include "access/heapam.h"
#include <access/htup.h> #include "catalog/pg_type.h"
#include <access/transam.h>
#include <access/tupmacs.h>
#include <catalog/pg_type.h>
#include <storage/bufpage.h>
#include <utils/memutils.h>
#ifndef HAVE_MEMMOVE
#include <regex/utils.h>
#else
#include <string.h>
#endif
/* Used by heap_getattr() macro, for speed */ /* Used by heap_getattr() macro, for speed */
long heap_sysoffset[] = { long heap_sysoffset[] = {
@@ -688,7 +677,7 @@ heap_formtuple(TupleDesc tupleDescriptor,
len += bitmaplen; len += bitmaplen;
} }
hoff = len = DOUBLEALIGN(len); /* be conservative here */ hoff = len = MAXALIGN(len); /* be conservative here */
len += ComputeDataSize(tupleDescriptor, value, nulls); len += ComputeDataSize(tupleDescriptor, value, nulls);
@@ -822,7 +811,7 @@ heap_addheader(uint32 natts, /* max domain index */
len = offsetof(HeapTupleHeaderData, t_bits); len = offsetof(HeapTupleHeaderData, t_bits);
hoff = len = DOUBLEALIGN(len); /* be conservative */ hoff = len = MAXALIGN(len); /* be conservative */
len += structlen; len += structlen;
tuple = (HeapTuple) palloc(HEAPTUPLESIZE + len); tuple = (HeapTuple) palloc(HEAPTUPLESIZE + len);
td = tuple->t_data = (HeapTupleHeader) ((char *) tuple + HEAPTUPLESIZE); td = tuple->t_data = (HeapTupleHeader) ((char *) tuple + HEAPTUPLESIZE);

View File

@@ -8,24 +8,17 @@
* *
* *
* IDENTIFICATION * IDENTIFICATION
* $Header: /cvsroot/pgsql/src/backend/access/common/indextuple.c,v 1.33 1999/02/13 23:14:11 momjian Exp $ * $Header: /cvsroot/pgsql/src/backend/access/common/indextuple.c,v 1.33.2.1 1999/08/02 05:24:25 scrappy Exp $
* *
*------------------------------------------------------------------------- *-------------------------------------------------------------------------
*/ */
#include <postgres.h> #include "postgres.h"
#include <access/heapam.h> #include "access/heapam.h"
#include <access/ibit.h> #include "access/itup.h"
#include <access/itup.h> #include "catalog/pg_type.h"
#include <access/tupmacs.h>
#include <catalog/pg_type.h>
#ifndef HAVE_MEMMOVE
#include <regex/utils.h>
#else
#include <string.h>
#endif
/* ---------------------------------------------------------------- /* ----------------------------------------------------------------
* index_ tuple interface routines * index_ tuple interface routines
@@ -67,7 +60,7 @@ index_formtuple(TupleDesc tupleDescriptor,
hoff = IndexInfoFindDataOffset(infomask); hoff = IndexInfoFindDataOffset(infomask);
size = hoff + ComputeDataSize(tupleDescriptor, value, null); size = hoff + ComputeDataSize(tupleDescriptor, value, null);
size = DOUBLEALIGN(size); /* be conservative */ size = MAXALIGN(size); /* be conservative */
tp = (char *) palloc(size); tp = (char *) palloc(size);
tuple = (IndexTuple) tp; tuple = (IndexTuple) tp;

View File

@@ -7,19 +7,15 @@
* *
* *
* IDENTIFICATION * IDENTIFICATION
* $Header: /cvsroot/pgsql/src/backend/access/common/Attic/indexvalid.c,v 1.21 1999/02/13 23:14:12 momjian Exp $ * $Header: /cvsroot/pgsql/src/backend/access/common/Attic/indexvalid.c,v 1.21.2.1 1999/08/02 05:24:25 scrappy Exp $
* *
*------------------------------------------------------------------------- *-------------------------------------------------------------------------
*/ */
#include <postgres.h> #include "postgres.h"
#include <fmgr.h>
#include <access/htup.h> #include "access/iqual.h"
#include <access/iqual.h> #include "executor/execdebug.h"
#include <access/itup.h>
#include <access/skey.h>
#include <executor/execdebug.h>
/* ---------------------------------------------------------------- /* ----------------------------------------------------------------
* index scan key qualification code * index scan key qualification code

View File

@@ -8,20 +8,17 @@
* *
* *
* IDENTIFICATION * IDENTIFICATION
* $Header: /cvsroot/pgsql/src/backend/access/common/printtup.c,v 1.47 1999/05/25 22:40:47 momjian Exp $ * $Header: /cvsroot/pgsql/src/backend/access/common/printtup.c,v 1.47.2.1 1999/08/02 05:24:25 scrappy Exp $
* *
*------------------------------------------------------------------------- *-------------------------------------------------------------------------
*/ */
#include <string.h>
#include "postgres.h" #include "postgres.h"
#include "fmgr.h"
#include "access/heapam.h" #include "access/heapam.h"
#include "access/printtup.h" #include "access/printtup.h"
#include "catalog/pg_type.h" #include "catalog/pg_type.h"
#include "libpq/libpq.h"
#include "libpq/pqformat.h" #include "libpq/pqformat.h"
#include "utils/syscache.h" #include "utils/syscache.h"

View File

@@ -7,15 +7,14 @@
* *
* *
* IDENTIFICATION * IDENTIFICATION
* $Header: /cvsroot/pgsql/src/backend/access/common/scankey.c,v 1.14 1999/05/25 16:06:41 momjian Exp $ * $Header: /cvsroot/pgsql/src/backend/access/common/scankey.c,v 1.14.2.1 1999/08/02 05:24:26 scrappy Exp $
* *
*------------------------------------------------------------------------- *-------------------------------------------------------------------------
*/ */
#include <postgres.h> #include "postgres.h"
#include <fmgr.h> #include "access/skey.h"
#include <access/skey.h>
/* /*
* ScanKeyEntryIsLegal * ScanKeyEntryIsLegal

View File

@@ -7,7 +7,7 @@
* *
* *
* IDENTIFICATION * IDENTIFICATION
* $Header: /cvsroot/pgsql/src/backend/access/common/tupdesc.c,v 1.50 1999/05/25 22:40:48 momjian Exp $ * $Header: /cvsroot/pgsql/src/backend/access/common/tupdesc.c,v 1.50.2.1 1999/08/02 05:24:26 scrappy Exp $
* *
* NOTES * NOTES
* some of the executor utility code such as "ExecTypeFromTL" should be * some of the executor utility code such as "ExecTypeFromTL" should be
@@ -16,22 +16,14 @@
*------------------------------------------------------------------------- *-------------------------------------------------------------------------
*/ */
#include <stdio.h> #include "postgres.h"
#include <postgres.h> #include "catalog/pg_type.h"
#include "nodes/parsenodes.h"
#include "parser/parse_type.h"
#include "utils/builtins.h"
#include "utils/syscache.h"
#include <catalog/pg_type.h>
#include <nodes/parsenodes.h>
#include <parser/parse_type.h>
#include <utils/builtins.h>
#include <utils/fcache.h>
#include <utils/syscache.h>
#ifndef HAVE_MEMMOVE
#include <regex/utils.h>
#else
#include <string.h>
#endif
/* ---------------------------------------------------------------- /* ----------------------------------------------------------------
* CreateTemplateTupleDesc * CreateTemplateTupleDesc

View File

@@ -6,31 +6,22 @@
* *
* *
* IDENTIFICATION * IDENTIFICATION
* * $Header: /cvsroot/pgsql/src/backend/access/gist/gist.c,v 1.38.2.1 1999/08/02 05:24:28 scrappy Exp $
* *
*------------------------------------------------------------------------- *-------------------------------------------------------------------------
*/ */
#include <postgres.h> #include "postgres.h"
#include <fmgr.h> #include "access/genam.h"
#include <access/genam.h> #include "access/gist.h"
#include <access/gist.h> #include "access/gistscan.h"
#include <access/gistscan.h> #include "access/heapam.h"
#include <access/heapam.h> #include "catalog/index.h"
#include <catalog/index.h> #include "catalog/pg_index.h"
#include <executor/executor.h> #include "executor/executor.h"
#include <storage/bufmgr.h> #include "utils/syscache.h"
#include <storage/bufpage.h>
#include <storage/lmgr.h>
#include <utils/syscache.h>
#include <utils/tqual.h>
#ifndef HAVE_MEMMOVE
#include <regex/utils.h>
#else
#include <string.h>
#endif
/* non-export function prototypes */ /* non-export function prototypes */
static InsertIndexResult gistdoinsert(Relation r, IndexTuple itup, static InsertIndexResult gistdoinsert(Relation r, IndexTuple itup,
@@ -60,7 +51,9 @@ void gistdelete(Relation r, ItemPointer tid);
static IndexTuple gist_tuple_replacekey(Relation r, GISTENTRY entry, IndexTuple t); static IndexTuple gist_tuple_replacekey(Relation r, GISTENTRY entry, IndexTuple t);
static void gistcentryinit(GISTSTATE *giststate, GISTENTRY *e, char *pr, static void gistcentryinit(GISTSTATE *giststate, GISTENTRY *e, char *pr,
Relation r, Page pg, OffsetNumber o, int b, bool l); Relation r, Page pg, OffsetNumber o, int b, bool l);
#ifdef GISTDEBUG
static char *int_range_out(INTRANGE *r); static char *int_range_out(INTRANGE *r);
#endif
/* /*
** routine to build an index. Basically calls insert over and over ** routine to build an index. Basically calls insert over and over

View File

@@ -11,21 +11,11 @@
*------------------------------------------------------------------------- *-------------------------------------------------------------------------
*/ */
#include <postgres.h> #include "postgres.h"
#include <access/relscan.h> #include "access/gist.h"
#include <storage/bufpage.h> #include "executor/execdebug.h"
#include <access/sdir.h>
#include <access/itup.h>
#include <access/gist.h>
#include <executor/execdebug.h>
#include <storage/bufmgr.h>
#ifndef HAVE_MEMMOVE
#include <regex/utils.h>
#else
#include <string.h>
#endif
static OffsetNumber gistfindnext(IndexScanDesc s, Page p, OffsetNumber n, static OffsetNumber gistfindnext(IndexScanDesc s, Page p, OffsetNumber n,

View File

@@ -10,21 +10,12 @@
*------------------------------------------------------------------------- *-------------------------------------------------------------------------
*/ */
#include <postgres.h> #include "postgres.h"
#include <access/gist.h> #include "access/genam.h"
#include <access/gistscan.h> #include "access/gist.h"
#include <access/genam.h> #include "access/gistscan.h"
#include <access/rtree.h>
#include <storage/bufmgr.h>
#include <access/giststrat.h>
#include <storage/lmgr.h>
#ifndef HAVE_MEMMOVE
#include <regex/utils.h>
#else
#include <string.h>
#endif
/* routines defined and used here */ /* routines defined and used here */
static void gistregscan(IndexScanDesc s); static void gistregscan(IndexScanDesc s);

View File

@@ -12,10 +12,10 @@
*------------------------------------------------------------------------- *-------------------------------------------------------------------------
*/ */
#include <postgres.h> #include "postgres.h"
#include <access/gist.h> #include "access/gist.h"
#include <access/istrat.h> #include "access/istrat.h"
/* /*
* Note: negate, commute, and negatecommute all assume that operators are * Note: negate, commute, and negatecommute all assume that operators are

View File

@@ -7,7 +7,7 @@
* *
* *
* IDENTIFICATION * IDENTIFICATION
* $Header: /cvsroot/pgsql/src/backend/access/hash/hash.c,v 1.26 1999/05/25 16:06:54 momjian Exp $ * $Header: /cvsroot/pgsql/src/backend/access/hash/hash.c,v 1.26.2.1 1999/08/02 05:24:33 scrappy Exp $
* *
* NOTES * NOTES
* This file contains only the public interface routines. * This file contains only the public interface routines.
@@ -15,21 +15,15 @@
*------------------------------------------------------------------------- *-------------------------------------------------------------------------
*/ */
#include <postgres.h> #include "postgres.h"
#include <access/hash.h> #include "access/genam.h"
#include <executor/executor.h> #include "access/hash.h"
#include <access/heapam.h> #include "access/heapam.h"
#include <access/genam.h> #include "catalog/index.h"
#include <catalog/index.h> #include "executor/executor.h"
#include <storage/bufmgr.h> #include "miscadmin.h"
#include <miscadmin.h>
#ifndef HAVE_MEMMOVE
#include <regex/utils.h>
#else
#include <string.h>
#endif
bool BuildingHash = false; bool BuildingHash = false;

View File

@@ -7,7 +7,7 @@
* *
* *
* IDENTIFICATION * IDENTIFICATION
* $Header: /cvsroot/pgsql/src/backend/access/hash/hashfunc.c,v 1.18 1999/05/25 22:40:49 momjian Exp $ * $Header: /cvsroot/pgsql/src/backend/access/hash/hashfunc.c,v 1.18.2.1 1999/08/02 05:24:33 scrappy Exp $
* *
* NOTES * NOTES
* These functions are stored in pg_amproc. For each operator class * These functions are stored in pg_amproc. For each operator class
@@ -19,7 +19,6 @@
#include "postgres.h" #include "postgres.h"
#include "access/hash.h" #include "access/hash.h"
#include "utils/int8.h"
uint32 uint32
hashint2(int16 key) hashint2(int16 key)

View File

@@ -7,16 +7,14 @@
* *
* *
* IDENTIFICATION * IDENTIFICATION
* $Header: /cvsroot/pgsql/src/backend/access/hash/hashinsert.c,v 1.15 1999/02/13 23:14:19 momjian Exp $ * $Header: /cvsroot/pgsql/src/backend/access/hash/hashinsert.c,v 1.15.2.1 1999/08/02 05:24:33 scrappy Exp $
* *
*------------------------------------------------------------------------- *-------------------------------------------------------------------------
*/ */
#include <postgres.h> #include "postgres.h"
#include <access/hash.h> #include "access/hash.h"
#include <storage/bufmgr.h>
#include <utils/memutils.h>
static InsertIndexResult _hash_insertonpg(Relation rel, Buffer buf, int keysz, ScanKey scankey, HashItem hitem, Buffer metabuf); static InsertIndexResult _hash_insertonpg(Relation rel, Buffer buf, int keysz, ScanKey scankey, HashItem hitem, Buffer metabuf);
static OffsetNumber _hash_pgaddtup(Relation rel, Buffer buf, int keysz, ScanKey itup_scankey, Size itemsize, HashItem hitem); static OffsetNumber _hash_pgaddtup(Relation rel, Buffer buf, int keysz, ScanKey itup_scankey, Size itemsize, HashItem hitem);
@@ -130,7 +128,7 @@ _hash_insertonpg(Relation rel,
itemsz = IndexTupleDSize(hitem->hash_itup) itemsz = IndexTupleDSize(hitem->hash_itup)
+ (sizeof(HashItemData) - sizeof(IndexTupleData)); + (sizeof(HashItemData) - sizeof(IndexTupleData));
itemsz = DOUBLEALIGN(itemsz); itemsz = MAXALIGN(itemsz);
while (PageGetFreeSpace(page) < itemsz) while (PageGetFreeSpace(page) < itemsz)
{ {

View File

@@ -7,24 +7,17 @@
* *
* *
* IDENTIFICATION * IDENTIFICATION
* $Header: /cvsroot/pgsql/src/backend/access/hash/hashovfl.c,v 1.20 1999/02/13 23:14:19 momjian Exp $ * $Header: /cvsroot/pgsql/src/backend/access/hash/hashovfl.c,v 1.20.2.1 1999/08/02 05:24:34 scrappy Exp $
* *
* NOTES * NOTES
* Overflow pages look like ordinary relation pages. * Overflow pages look like ordinary relation pages.
* *
*------------------------------------------------------------------------- *-------------------------------------------------------------------------
*/ */
#include <postgres.h> #include "postgres.h"
#include <access/hash.h> #include "access/hash.h"
#include <storage/bufmgr.h>
#include <utils/memutils.h>
#ifndef HAVE_MEMMOVE
#include <regex/utils.h>
#else
#include <string.h>
#endif
static OverflowPageAddress _hash_getovfladdr(Relation rel, Buffer *metabufp); static OverflowPageAddress _hash_getovfladdr(Relation rel, Buffer *metabufp);
static uint32 _hash_firstfreebit(uint32 map); static uint32 _hash_firstfreebit(uint32 map);
@@ -538,7 +531,7 @@ _hash_squeezebucket(Relation rel,
hitem = (HashItem) PageGetItem(rpage, PageGetItemId(rpage, roffnum)); hitem = (HashItem) PageGetItem(rpage, PageGetItemId(rpage, roffnum));
itemsz = IndexTupleDSize(hitem->hash_itup) itemsz = IndexTupleDSize(hitem->hash_itup)
+ (sizeof(HashItemData) - sizeof(IndexTupleData)); + (sizeof(HashItemData) - sizeof(IndexTupleData));
itemsz = DOUBLEALIGN(itemsz); itemsz = MAXALIGN(itemsz);
/* /*
* walk up the bucket chain, looking for a page big enough for * walk up the bucket chain, looking for a page big enough for

View File

@@ -7,7 +7,7 @@
* *
* *
* IDENTIFICATION * IDENTIFICATION
* $Header: /cvsroot/pgsql/src/backend/access/hash/hashscan.c,v 1.17 1999/02/13 23:14:20 momjian Exp $ * $Header: /cvsroot/pgsql/src/backend/access/hash/hashscan.c,v 1.17.2.1 1999/08/02 05:24:35 scrappy Exp $
* *
* NOTES * NOTES
* Because we can be doing an index scan on a relation while we * Because we can be doing an index scan on a relation while we
@@ -27,9 +27,9 @@
*------------------------------------------------------------------------- *-------------------------------------------------------------------------
*/ */
#include <postgres.h> #include "postgres.h"
#include <access/hash.h> #include "access/hash.h"
static void _hash_scandel(IndexScanDesc scan, BlockNumber blkno, OffsetNumber offno); static void _hash_scandel(IndexScanDesc scan, BlockNumber blkno, OffsetNumber offno);
static bool _hash_scantouched(IndexScanDesc scan, BlockNumber blkno, OffsetNumber offno); static bool _hash_scantouched(IndexScanDesc scan, BlockNumber blkno, OffsetNumber offno);

View File

@@ -7,21 +7,15 @@
* *
* *
* IDENTIFICATION * IDENTIFICATION
* $Header: /cvsroot/pgsql/src/backend/access/hash/hashsearch.c,v 1.17 1999/02/13 23:14:20 momjian Exp $ * $Header: /cvsroot/pgsql/src/backend/access/hash/hashsearch.c,v 1.17.2.1 1999/08/02 05:24:35 scrappy Exp $
* *
*------------------------------------------------------------------------- *-------------------------------------------------------------------------
*/ */
#include <postgres.h> #include "postgres.h"
#include <access/hash.h> #include "access/hash.h"
#include <storage/bufmgr.h>
#ifndef HAVE_MEMMOVE
#include "regex/utils.h"
#else
#include <string.h>
#endif
/* /*
* _hash_search() -- Finds the page/bucket that the contains the * _hash_search() -- Finds the page/bucket that the contains the

View File

@@ -7,15 +7,13 @@
* *
* *
* IDENTIFICATION * IDENTIFICATION
* $Header: /cvsroot/pgsql/src/backend/access/hash/Attic/hashstrat.c,v 1.13 1999/02/13 23:14:21 momjian Exp $ * $Header: /cvsroot/pgsql/src/backend/access/hash/Attic/hashstrat.c,v 1.13.2.1 1999/08/02 05:24:36 scrappy Exp $
* *
*------------------------------------------------------------------------- *-------------------------------------------------------------------------
*/ */
#include <postgres.h> #include "postgres.h"
#include <access/hash.h>
#include <access/istrat.h>
/* /*
* only one valid strategy for hash tables: equality. * only one valid strategy for hash tables: equality.

View File

@@ -7,23 +7,16 @@
* *
* *
* IDENTIFICATION * IDENTIFICATION
* $Header: /cvsroot/pgsql/src/backend/access/hash/hashutil.c,v 1.15 1999/02/13 23:14:21 momjian Exp $ * $Header: /cvsroot/pgsql/src/backend/access/hash/hashutil.c,v 1.15.2.1 1999/08/02 05:24:36 scrappy Exp $
* *
*------------------------------------------------------------------------- *-------------------------------------------------------------------------
*/ */
#include <postgres.h> #include "postgres.h"
#include <access/hash.h> #include "access/hash.h"
#include <fmgr.h> #include "access/iqual.h"
#include <utils/memutils.h>
#include <access/iqual.h>
#ifndef HAVE_MEMMOVE
#include <regex/utils.h>
#else
#include <string.h>
#endif
ScanKey ScanKey
_hash_mkscankey(Relation rel, IndexTuple itup, HashMetaPage metap) _hash_mkscankey(Relation rel, IndexTuple itup, HashMetaPage metap)
@@ -134,9 +127,9 @@ _hash_checkpage(Page page, int flags)
Assert(((PageHeader) (page))->pd_lower >= (sizeof(PageHeaderData) - sizeof(ItemIdData))); Assert(((PageHeader) (page))->pd_lower >= (sizeof(PageHeaderData) - sizeof(ItemIdData)));
#if 1 #if 1
Assert(((PageHeader) (page))->pd_upper <= Assert(((PageHeader) (page))->pd_upper <=
(BLCKSZ - DOUBLEALIGN(sizeof(HashPageOpaqueData)))); (BLCKSZ - MAXALIGN(sizeof(HashPageOpaqueData))));
Assert(((PageHeader) (page))->pd_special == Assert(((PageHeader) (page))->pd_special ==
(BLCKSZ - DOUBLEALIGN(sizeof(HashPageOpaqueData)))); (BLCKSZ - MAXALIGN(sizeof(HashPageOpaqueData))));
Assert(((PageHeader) (page))->pd_opaque.od_pagesize == BLCKSZ); Assert(((PageHeader) (page))->pd_opaque.od_pagesize == BLCKSZ);
#endif #endif
if (flags) if (flags)

View File

@@ -7,7 +7,7 @@
* *
* *
* IDENTIFICATION * IDENTIFICATION
* $Header: /cvsroot/pgsql/src/backend/access/heap/Attic/stats.c,v 1.16 1999/07/03 00:32:36 momjian Exp $ * $Header: /cvsroot/pgsql/src/backend/access/heap/Attic/stats.c,v 1.16.2.1 1999/08/02 05:24:37 scrappy Exp $
* *
* NOTES * NOTES
* initam should be moved someplace else. * initam should be moved someplace else.
@@ -15,19 +15,12 @@
*------------------------------------------------------------------------- *-------------------------------------------------------------------------
*/ */
#include <stdio.h>
#include <time.h> #include <time.h>
#include <postgres.h> #include "postgres.h"
#include <access/heapam.h> #include "access/heapam.h"
#include <utils/mcxt.h>
#ifndef HAVE_MEMMOVE
#include <regex/utils.h>
#else
#include <string.h>
#endif
static void InitHeapAccessStatistics(void); static void InitHeapAccessStatistics(void);

View File

@@ -7,7 +7,7 @@
* *
* *
* IDENTIFICATION * IDENTIFICATION
* $Header: /cvsroot/pgsql/src/backend/access/index/genam.c,v 1.17 1999/05/25 16:07:12 momjian Exp $ * $Header: /cvsroot/pgsql/src/backend/access/index/genam.c,v 1.17.2.1 1999/08/02 05:24:38 scrappy Exp $
* *
* NOTES * NOTES
* many of the old access method routines have been turned into * many of the old access method routines have been turned into
@@ -44,17 +44,9 @@
* ---------------------------------------------------------------- * ----------------------------------------------------------------
*/ */
#include <postgres.h> #include "postgres.h"
#include "access/genam.h"
#include <utils/catcache.h>
#include <access/genam.h>
#include <storage/bufmgr.h>
#ifndef HAVE_MEMMOVE
#include <regex/utils.h>
#else
#include <string.h>
#endif
/* ---------------------------------------------------------------- /* ----------------------------------------------------------------
* general access method routines * general access method routines

View File

@@ -8,14 +8,13 @@
* *
* *
* IDENTIFICATION * IDENTIFICATION
* $Header: /cvsroot/pgsql/src/backend/access/index/Attic/istrat.c,v 1.33 1999/06/19 04:54:10 momjian Exp $ * $Header: /cvsroot/pgsql/src/backend/access/index/Attic/istrat.c,v 1.33.2.1 1999/08/02 05:24:39 scrappy Exp $
* *
*------------------------------------------------------------------------- *-------------------------------------------------------------------------
*/ */
#include "postgres.h" #include "postgres.h"
#include "miscadmin.h"
#include "access/heapam.h" #include "access/heapam.h"
#include "access/istrat.h" #include "access/istrat.h"
#include "catalog/catname.h" #include "catalog/catname.h"
@@ -23,9 +22,8 @@
#include "catalog/pg_amproc.h" #include "catalog/pg_amproc.h"
#include "catalog/pg_index.h" #include "catalog/pg_index.h"
#include "catalog/pg_operator.h" #include "catalog/pg_operator.h"
#include "miscadmin.h"
#include "utils/syscache.h" #include "utils/syscache.h"
#include "fmgr.h"
#include "utils/memutils.h" /* could have been access/itup.h */
#ifdef USE_ASSERT_CHECKING #ifdef USE_ASSERT_CHECKING
static bool StrategyEvaluationIsValid(StrategyEvaluation evaluation); static bool StrategyEvaluationIsValid(StrategyEvaluation evaluation);

View File

@@ -7,7 +7,7 @@
* *
* *
* IDENTIFICATION * IDENTIFICATION
* $Header: /cvsroot/pgsql/src/backend/access/nbtree/nbtcompare.c,v 1.24 1999/05/25 22:40:50 momjian Exp $ * $Header: /cvsroot/pgsql/src/backend/access/nbtree/nbtcompare.c,v 1.24.2.1 1999/08/02 05:24:40 scrappy Exp $
* *
* NOTES * NOTES
* These functions are stored in pg_amproc. For each operator class * These functions are stored in pg_amproc. For each operator class
@@ -20,12 +20,10 @@
*------------------------------------------------------------------------- *-------------------------------------------------------------------------
*/ */
#include <string.h>
#include <postgres.h> #include "postgres.h"
#include <utils/builtins.h> #include "utils/builtins.h"
#include <utils/nabstime.h>
int32 int32
btint2cmp(int16 a, int16 b) btint2cmp(int16 a, int16 b)

View File

@@ -7,25 +7,16 @@
* *
* *
* IDENTIFICATION * IDENTIFICATION
* $Header: /cvsroot/pgsql/src/backend/access/nbtree/nbtinsert.c,v 1.42 1999/05/25 22:04:11 momjian Exp $ * $Header: /cvsroot/pgsql/src/backend/access/nbtree/nbtinsert.c,v 1.42.2.1 1999/08/02 05:24:40 scrappy Exp $
* *
*------------------------------------------------------------------------- *-------------------------------------------------------------------------
*/ */
#include <postgres.h> #include "postgres.h"
#include <utils/memutils.h> #include "access/heapam.h"
#include <storage/bufpage.h> #include "access/nbtree.h"
#include <access/nbtree.h>
#include <access/heapam.h>
#include <access/xact.h>
#include <fmgr.h>
#ifndef HAVE_MEMMOVE
#include <regex/utils.h>
#else
#include <string.h>
#endif
static InsertIndexResult _bt_insertonpg(Relation rel, Buffer buf, BTStack stack, int keysz, ScanKey scankey, BTItem btitem, BTItem afteritem); static InsertIndexResult _bt_insertonpg(Relation rel, Buffer buf, BTStack stack, int keysz, ScanKey scankey, BTItem btitem, BTItem afteritem);
static Buffer _bt_split(Relation rel, Buffer buf, OffsetNumber firstright); static Buffer _bt_split(Relation rel, Buffer buf, OffsetNumber firstright);
@@ -272,7 +263,7 @@ _bt_insertonpg(Relation rel,
itemsz = IndexTupleDSize(btitem->bti_itup) itemsz = IndexTupleDSize(btitem->bti_itup)
+ (sizeof(BTItemData) - sizeof(IndexTupleData)); + (sizeof(BTItemData) - sizeof(IndexTupleData));
itemsz = DOUBLEALIGN(itemsz); /* be safe, PageAddItem will do itemsz = MAXALIGN(itemsz); /* be safe, PageAddItem will do
* this but we need to be * this but we need to be
* consistent */ * consistent */
@@ -378,7 +369,7 @@ _bt_insertonpg(Relation rel,
if (currsize > maxsize) if (currsize > maxsize)
maxsize = currsize; maxsize = currsize;
maxsize += sizeof(PageHeaderData) + maxsize += sizeof(PageHeaderData) +
DOUBLEALIGN(sizeof(BTPageOpaqueData)); MAXALIGN(sizeof(BTPageOpaqueData));
if (maxsize >= PageGetPageSize(page) / 2) if (maxsize >= PageGetPageSize(page) / 2)
do_split = true; do_split = true;
} }
@@ -469,7 +460,7 @@ _bt_insertonpg(Relation rel,
maxoff = PageGetMaxOffsetNumber(page); maxoff = PageGetMaxOffsetNumber(page);
llimit = PageGetPageSize(page) - sizeof(PageHeaderData) - llimit = PageGetPageSize(page) - sizeof(PageHeaderData) -
DOUBLEALIGN(sizeof(BTPageOpaqueData)) MAXALIGN(sizeof(BTPageOpaqueData))
+sizeof(ItemIdData); +sizeof(ItemIdData);
llimit /= 2; llimit /= 2;
firstright = _bt_findsplitloc(rel, page, start, maxoff, llimit); firstright = _bt_findsplitloc(rel, page, start, maxoff, llimit);
@@ -698,8 +689,8 @@ l_spl: ;
* then we must forse insertion. * then we must forse insertion.
*/ */
if (!parent_chained && if (!parent_chained &&
DOUBLEALIGN(IndexTupleDSize(lowLeftItem->bti_itup)) == MAXALIGN(IndexTupleDSize(lowLeftItem->bti_itup)) ==
DOUBLEALIGN(IndexTupleDSize(stack->bts_btitem->bti_itup))) MAXALIGN(IndexTupleDSize(stack->bts_btitem->bti_itup)))
{ {
_bt_updateitem(rel, keysz, pbuf, _bt_updateitem(rel, keysz, pbuf,
stack->bts_btitem, lowLeftItem); stack->bts_btitem, lowLeftItem);
@@ -1600,7 +1591,7 @@ _bt_shift(Relation rel, Buffer buf, BTStack stack, int keysz,
/* add passed hikey */ /* add passed hikey */
itemsz = IndexTupleDSize(hikey->bti_itup) itemsz = IndexTupleDSize(hikey->bti_itup)
+ (sizeof(BTItemData) - sizeof(IndexTupleData)); + (sizeof(BTItemData) - sizeof(IndexTupleData));
itemsz = DOUBLEALIGN(itemsz); itemsz = MAXALIGN(itemsz);
if (PageAddItem(page, (Item) hikey, itemsz, P_HIKEY, LP_USED) == InvalidOffsetNumber) if (PageAddItem(page, (Item) hikey, itemsz, P_HIKEY, LP_USED) == InvalidOffsetNumber)
elog(FATAL, "btree: failed to add hikey in _bt_shift"); elog(FATAL, "btree: failed to add hikey in _bt_shift");
pfree(hikey); pfree(hikey);
@@ -1608,7 +1599,7 @@ _bt_shift(Relation rel, Buffer buf, BTStack stack, int keysz,
/* add btitem */ /* add btitem */
itemsz = IndexTupleDSize(btitem->bti_itup) itemsz = IndexTupleDSize(btitem->bti_itup)
+ (sizeof(BTItemData) - sizeof(IndexTupleData)); + (sizeof(BTItemData) - sizeof(IndexTupleData));
itemsz = DOUBLEALIGN(itemsz); itemsz = MAXALIGN(itemsz);
if (PageAddItem(page, (Item) btitem, itemsz, P_FIRSTKEY, LP_USED) == InvalidOffsetNumber) if (PageAddItem(page, (Item) btitem, itemsz, P_FIRSTKEY, LP_USED) == InvalidOffsetNumber)
elog(FATAL, "btree: failed to add firstkey in _bt_shift"); elog(FATAL, "btree: failed to add firstkey in _bt_shift");
pfree(btitem); pfree(btitem);

View File

@@ -8,7 +8,7 @@
* *
* *
* IDENTIFICATION * IDENTIFICATION
* $Header: /cvsroot/pgsql/src/backend/access/nbtree/nbtpage.c,v 1.24 1999/06/07 14:28:22 vadim Exp $ * $Header: /cvsroot/pgsql/src/backend/access/nbtree/nbtpage.c,v 1.24.2.1 1999/08/02 05:24:41 scrappy Exp $
* *
* NOTES * NOTES
* Postgres btree pages look like ordinary relation pages. The opaque * Postgres btree pages look like ordinary relation pages. The opaque
@@ -19,21 +19,12 @@
* *
*------------------------------------------------------------------------- *-------------------------------------------------------------------------
*/ */
#include <stdio.h>
#include <time.h> #include <time.h>
#include <postgres.h> #include "postgres.h"
#include <storage/bufpage.h> #include "access/nbtree.h"
#include <access/nbtree.h> #include "miscadmin.h"
#include <miscadmin.h>
#include <storage/lmgr.h>
#ifndef HAVE_MEMMOVE
#include <regex/utils.h>
#else
#include <string.h>
#endif
#define BTREE_METAPAGE 0 #define BTREE_METAPAGE 0
#define BTREE_MAGIC 0x053162 #define BTREE_MAGIC 0x053162

View File

@@ -8,7 +8,7 @@
* *
* *
* IDENTIFICATION * IDENTIFICATION
* $Header: /cvsroot/pgsql/src/backend/access/nbtree/nbtree.c,v 1.41 1999/06/07 15:14:54 vadim Exp $ * $Header: /cvsroot/pgsql/src/backend/access/nbtree/nbtree.c,v 1.41.2.1 1999/08/02 05:24:41 scrappy Exp $
* *
* NOTES * NOTES
* This file contains only the public interface routines. * This file contains only the public interface routines.
@@ -16,26 +16,16 @@
*------------------------------------------------------------------------- *-------------------------------------------------------------------------
*/ */
#include <postgres.h> #include "postgres.h"
#include <access/genam.h> #include "access/genam.h"
#include <storage/bufpage.h> #include "access/heapam.h"
#include <storage/bufmgr.h> #include "access/nbtree.h"
#include <access/nbtree.h> #include "catalog/index.h"
#include <executor/executor.h> #include "executor/executor.h"
#include <access/heapam.h> #include "miscadmin.h"
#include <catalog/index.h>
#include <miscadmin.h>
#ifndef HAVE_MEMMOVE
#include <regex/utils.h>
#else
#include <string.h>
#endif
#ifdef BTREE_BUILD_STATS #ifdef BTREE_BUILD_STATS
#include <tcop/tcopprot.h>
#include <utils/trace.h>
#define ShowExecutorStats pg_options[TRACE_EXECUTORSTATS] #define ShowExecutorStats pg_options[TRACE_EXECUTORSTATS]
#endif #endif

View File

@@ -7,7 +7,7 @@
* *
* *
* IDENTIFICATION * IDENTIFICATION
* $Header: /cvsroot/pgsql/src/backend/access/nbtree/Attic/nbtscan.c,v 1.23 1999/05/25 22:04:14 momjian Exp $ * $Header: /cvsroot/pgsql/src/backend/access/nbtree/Attic/nbtscan.c,v 1.23.2.1 1999/08/02 05:24:41 scrappy Exp $
* *
* *
* NOTES * NOTES
@@ -27,10 +27,9 @@
*------------------------------------------------------------------------- *-------------------------------------------------------------------------
*/ */
#include <postgres.h> #include "postgres.h"
#include <storage/bufpage.h> #include "access/nbtree.h"
#include <access/nbtree.h>
typedef struct BTScanListData typedef struct BTScanListData
{ {

View File

@@ -5,7 +5,7 @@
* *
* *
* IDENTIFICATION * IDENTIFICATION
* $Id: nbtsort.c,v 1.40 1999/05/25 18:20:31 vadim Exp $ * $Id: nbtsort.c,v 1.40.2.1 1999/08/02 05:24:41 scrappy Exp $
* *
* NOTES * NOTES
* *
@@ -52,18 +52,9 @@
#include "postgres.h" #include "postgres.h"
#include "access/nbtree.h" #include "access/nbtree.h"
#include "storage/bufpage.h"
#include "utils/memutils.h"
#ifndef HAVE_MEMMOVE
#include <regex/utils.h>
#else
#include <string.h>
#endif
#ifdef BTREE_BUILD_STATS #ifdef BTREE_BUILD_STATS
#include "tcop/tcopprot.h"
#include <utils/trace.h>
#define ShowExecutorStats pg_options[TRACE_EXECUTORSTATS] #define ShowExecutorStats pg_options[TRACE_EXECUTORSTATS]
#endif #endif
@@ -95,7 +86,7 @@ extern int NDirectFileWrite;
* are potentially reading a bunch of zeroes off of disk in many * are potentially reading a bunch of zeroes off of disk in many
* cases. * cases.
* *
* BTItems are packed in and DOUBLEALIGN'd. * BTItems are packed in and MAXALIGN'd.
* *
* the fd should not be going out to disk, strictly speaking, but it's * the fd should not be going out to disk, strictly speaking, but it's
* the only thing like that so i'm not going to worry about wasting a * the only thing like that so i'm not going to worry about wasting a
@@ -506,7 +497,7 @@ _bt_tapenext(BTTapeBlock *tape, char **pos)
return (BTItem) NULL; return (BTItem) NULL;
bti = (BTItem) *pos; bti = (BTItem) *pos;
itemsz = BTITEMSZ(bti); itemsz = BTITEMSZ(bti);
*pos += DOUBLEALIGN(itemsz); *pos += MAXALIGN(itemsz);
return bti; return bti;
} }
@@ -526,7 +517,7 @@ _bt_tapeadd(BTTapeBlock *tape, BTItem item, int itemsz)
{ {
memcpy(tape->bttb_data + tape->bttb_top, item, itemsz); memcpy(tape->bttb_data + tape->bttb_top, item, itemsz);
++tape->bttb_ntup; ++tape->bttb_ntup;
tape->bttb_top += DOUBLEALIGN(itemsz); tape->bttb_top += MAXALIGN(itemsz);
} }
/*------------------------------------------------------------------------- /*-------------------------------------------------------------------------
@@ -662,7 +653,7 @@ _bt_spool(Relation index, BTItem btitem, void *spool)
itape = btspool->bts_itape[btspool->bts_tape]; itape = btspool->bts_itape[btspool->bts_tape];
itemsz = BTITEMSZ(btitem); itemsz = BTITEMSZ(btitem);
itemsz = DOUBLEALIGN(itemsz); itemsz = MAXALIGN(itemsz);
/* /*
* if this buffer is too full for this BTItemData, or if we have run * if this buffer is too full for this BTItemData, or if we have run
@@ -702,7 +693,7 @@ _bt_spool(Relation index, BTItem btitem, void *spool)
* BTItemDatas in the order dictated by the sorted array of * BTItemDatas in the order dictated by the sorted array of
* BTItems, not the original order. * BTItems, not the original order.
* *
* (since everything was DOUBLEALIGN'd and is all on a single tape * (since everything was MAXALIGN'd and is all on a single tape
* block, everything had *better* still fit on one tape block..) * block, everything had *better* still fit on one tape block..)
*/ */
otape = btspool->bts_otape[btspool->bts_tape]; otape = btspool->bts_otape[btspool->bts_tape];
@@ -710,7 +701,7 @@ _bt_spool(Relation index, BTItem btitem, void *spool)
{ {
bti = parray[i].btsk_item; bti = parray[i].btsk_item;
btisz = BTITEMSZ(bti); btisz = BTITEMSZ(bti);
btisz = DOUBLEALIGN(btisz); btisz = MAXALIGN(btisz);
_bt_tapeadd(otape, bti, btisz); _bt_tapeadd(otape, bti, btisz);
#if defined(FASTBUILD_DEBUG) && defined(FASTBUILD_SPOOL) #if defined(FASTBUILD_DEBUG) && defined(FASTBUILD_SPOOL)
{ {
@@ -912,7 +903,7 @@ _bt_buildadd(Relation index, void *pstate, BTItem bti, int flags)
pgspc = PageGetFreeSpace(npage); pgspc = PageGetFreeSpace(npage);
btisz = BTITEMSZ(bti); btisz = BTITEMSZ(bti);
btisz = DOUBLEALIGN(btisz); btisz = MAXALIGN(btisz);
if (pgspc < btisz) if (pgspc < btisz)
{ {
Buffer obuf = nbuf; Buffer obuf = nbuf;
@@ -1230,7 +1221,7 @@ _bt_merge(Relation index, BTSpool *btspool)
if (bti != (BTItem) NULL) if (bti != (BTItem) NULL)
{ {
btisz = BTITEMSZ(bti); btisz = BTITEMSZ(bti);
btisz = DOUBLEALIGN(btisz); btisz = MAXALIGN(btisz);
if (doleaf) if (doleaf)
{ {
_bt_buildadd(index, state, bti, BTP_LEAF); _bt_buildadd(index, state, bti, BTP_LEAF);

View File

@@ -7,16 +7,15 @@
* *
* *
* IDENTIFICATION * IDENTIFICATION
* $Header: /cvsroot/pgsql/src/backend/access/nbtree/Attic/nbtstrat.c,v 1.8 1999/02/13 23:14:37 momjian Exp $ * $Header: /cvsroot/pgsql/src/backend/access/nbtree/Attic/nbtstrat.c,v 1.8.2.1 1999/08/02 05:24:42 scrappy Exp $
* *
*------------------------------------------------------------------------- *-------------------------------------------------------------------------
*/ */
#include <postgres.h> #include "postgres.h"
#include <access/istrat.h> #include "access/istrat.h"
#include <storage/bufpage.h> #include "access/nbtree.h"
#include <access/nbtree.h>
/* /*
* Note: * Note:

View File

@@ -7,7 +7,7 @@
* *
* *
* IDENTIFICATION * IDENTIFICATION
* $Header: /cvsroot/pgsql/src/backend/access/nbtree/nbtutils.c,v 1.27 1999/05/25 18:20:31 vadim Exp $ * $Header: /cvsroot/pgsql/src/backend/access/nbtree/nbtutils.c,v 1.27.2.1 1999/08/02 05:24:42 scrappy Exp $
* *
*------------------------------------------------------------------------- *-------------------------------------------------------------------------
*/ */
@@ -15,21 +15,13 @@
#include "postgres.h" #include "postgres.h"
#include "access/genam.h" #include "access/genam.h"
#include "access/iqual.h"
#include "access/istrat.h" #include "access/istrat.h"
#include "access/nbtree.h" #include "access/nbtree.h"
#include "executor/execdebug.h" #include "executor/execdebug.h"
#include "fmgr.h"
#include "storage/bufpage.h"
extern int NIndexTupleProcessed; extern int NIndexTupleProcessed;
#ifndef HAVE_MEMMOVE
#include <regex/utils.h>
#else
#include <string.h>
#endif
ScanKey ScanKey
_bt_mkscankey(Relation rel, IndexTuple itup) _bt_mkscankey(Relation rel, IndexTuple itup)

View File

@@ -7,24 +7,16 @@
* *
* *
* IDENTIFICATION * IDENTIFICATION
* $Header: /cvsroot/pgsql/src/backend/access/rtree/Attic/rtget.c,v 1.13 1999/02/13 23:14:41 momjian Exp $ * $Header: /cvsroot/pgsql/src/backend/access/rtree/Attic/rtget.c,v 1.13.2.1 1999/08/02 05:24:43 scrappy Exp $
* *
*------------------------------------------------------------------------- *-------------------------------------------------------------------------
*/ */
#include <postgres.h> #include "postgres.h"
#include "access/iqual.h"
#include "access/rtree.h"
#include <storage/bufmgr.h>
#include <access/sdir.h>
#include <access/relscan.h>
#include <access/iqual.h>
#include <access/rtree.h>
#include <storage/bufpage.h>
#ifndef HAVE_MEMMOVE
#include <regex/utils.h>
#else
#include <string.h>
#endif
static OffsetNumber findnext(IndexScanDesc s, Page p, OffsetNumber n, static OffsetNumber findnext(IndexScanDesc s, Page p, OffsetNumber n,

View File

@@ -7,20 +7,15 @@
* *
* *
* IDENTIFICATION * IDENTIFICATION
* $Header: /cvsroot/pgsql/src/backend/access/rtree/Attic/rtproc.c,v 1.18 1999/02/13 23:14:42 momjian Exp $ * $Header: /cvsroot/pgsql/src/backend/access/rtree/Attic/rtproc.c,v 1.18.2.1 1999/08/02 05:24:44 scrappy Exp $
* *
*------------------------------------------------------------------------- *-------------------------------------------------------------------------
*/ */
#include <postgres.h> #include "postgres.h"
#include "utils/builtins.h"
#include <utils/builtins.h>
#include <utils/geo_decls.h>
#ifndef HAVE_MEMMOVE
#include <regex/utils.h>
#else
#include <string.h>
#endif
BOX BOX
* *

View File

@@ -7,30 +7,20 @@
* *
* *
* IDENTIFICATION * IDENTIFICATION
* $Header: /cvsroot/pgsql/src/backend/access/rtree/Attic/rtree.c,v 1.32 1999/05/25 16:07:38 momjian Exp $ * $Header: /cvsroot/pgsql/src/backend/access/rtree/Attic/rtree.c,v 1.32.2.1 1999/08/02 05:24:44 scrappy Exp $
* *
*------------------------------------------------------------------------- *-------------------------------------------------------------------------
*/ */
#include <postgres.h> #include "postgres.h"
#include <access/genam.h> #include "access/genam.h"
#include <catalog/index.h> #include "access/heapam.h"
#include <access/rtscan.h> #include "access/rtree.h"
#include <storage/lmgr.h> #include "catalog/index.h"
#include <access/rtree.h> #include "executor/executor.h"
#include <storage/bufmgr.h> #include "utils/geo_decls.h"
#include <utils/geo_decls.h>
#include <executor/executor.h>
#include <access/heapam.h>
#include <fmgr.h>
#include <storage/bufpage.h>
#ifndef HAVE_MEMMOVE
#include <regex/utils.h>
#else
#include <string.h>
#endif
typedef struct SPLITVEC typedef struct SPLITVEC
{ {

View File

@@ -7,24 +7,16 @@
* *
* *
* IDENTIFICATION * IDENTIFICATION
* $Header: /cvsroot/pgsql/src/backend/access/rtree/Attic/rtscan.c,v 1.23 1999/05/25 16:07:40 momjian Exp $ * $Header: /cvsroot/pgsql/src/backend/access/rtree/Attic/rtscan.c,v 1.23.2.1 1999/08/02 05:24:44 scrappy Exp $
* *
*------------------------------------------------------------------------- *-------------------------------------------------------------------------
*/ */
#include <postgres.h> #include "postgres.h"
#include "access/genam.h"
#include "access/rtree.h"
#include <storage/bufmgr.h>
#include <access/genam.h>
#include <storage/lmgr.h>
#include <storage/bufpage.h>
#include <access/rtree.h>
#include <access/rtstrat.h>
#ifndef HAVE_MEMMOVE
#include <regex/utils.h>
#else
#include <string.h>
#endif
/* routines defined and used here */ /* routines defined and used here */

View File

@@ -7,16 +7,15 @@
* *
* *
* IDENTIFICATION * IDENTIFICATION
* $Header: /cvsroot/pgsql/src/backend/access/rtree/Attic/rtstrat.c,v 1.11 1999/02/13 23:14:43 momjian Exp $ * $Header: /cvsroot/pgsql/src/backend/access/rtree/Attic/rtstrat.c,v 1.11.2.1 1999/08/02 05:24:44 scrappy Exp $
* *
*------------------------------------------------------------------------- *-------------------------------------------------------------------------
*/ */
#include <postgres.h> #include "postgres.h"
#include <utils/rel.h> #include "access/istrat.h"
#include <access/rtree.h> #include "access/rtree.h"
#include <access/istrat.h>
static StrategyNumber RelationGetRTStrategy(Relation r, static StrategyNumber RelationGetRTStrategy(Relation r,
AttrNumber attnum, RegProcedure proc); AttrNumber attnum, RegProcedure proc);

View File

@@ -7,7 +7,7 @@
* *
* *
* IDENTIFICATION * IDENTIFICATION
* $Header: /cvsroot/pgsql/src/backend/access/transam/Attic/transsup.c,v 1.21 1999/03/30 01:37:21 momjian Exp $ * $Header: /cvsroot/pgsql/src/backend/access/transam/Attic/transsup.c,v 1.21.2.1 1999/08/02 05:24:46 scrappy Exp $
* *
* NOTES * NOTES
* This file contains support functions for the high * This file contains support functions for the high
@@ -16,12 +16,10 @@
*------------------------------------------------------------------------- *-------------------------------------------------------------------------
*/ */
#include <postgres.h> #include "postgres.h"
#include <access/transam.h> #include "access/xact.h"
#include <utils/bit.h> #include "utils/bit.h"
#include <access/xact.h>
#include <storage/lmgr.h>
static XidStatus TransBlockGetXidStatus(Block tblock, static XidStatus TransBlockGetXidStatus(Block tblock,
TransactionId transactionId); TransactionId transactionId);

View File

@@ -5,7 +5,7 @@
* *
* Copyright (c) 1994, Regents of the University of California * Copyright (c) 1994, Regents of the University of California
* *
* $Id: xid.c,v 1.22 1999/05/25 16:07:52 momjian Exp $ * $Id: xid.c,v 1.22.2.1 1999/08/02 05:24:46 scrappy Exp $
* *
* OLD COMMENTS * OLD COMMENTS
* XXX WARNING * XXX WARNING
@@ -18,10 +18,9 @@
*------------------------------------------------------------------------- *-------------------------------------------------------------------------
*/ */
#include <stdio.h>
#include <postgres.h> #include "postgres.h"
#include <access/xact.h> #include "access/xact.h"
extern TransactionId NullTransactionId; extern TransactionId NullTransactionId;
extern TransactionId DisabledTransactionId; extern TransactionId DisabledTransactionId;

View File

@@ -8,7 +8,7 @@
# #
# #
# IDENTIFICATION # IDENTIFICATION
# $Header: /cvsroot/pgsql/src/backend/utils/Attic/Gen_fmgrtab.sh.in,v 1.15 1999/04/09 22:35:41 tgl Exp $ # $Header: /cvsroot/pgsql/src/backend/utils/Attic/Gen_fmgrtab.sh.in,v 1.15.2.1 1999/08/02 05:24:47 scrappy Exp $
# #
# NOTES # NOTES
# Passes any -D options on to cpp prior to generating the list # Passes any -D options on to cpp prior to generating the list
@@ -83,7 +83,7 @@ cat > $HFILE <<FuNkYfMgRsTuFf
* *
* Copyright (c) 1994, Regents of the University of California * Copyright (c) 1994, Regents of the University of California
* *
* $Id: Gen_fmgrtab.sh.in,v 1.15 1999/04/09 22:35:41 tgl Exp $ * $Id: Gen_fmgrtab.sh.in,v 1.15.2.1 1999/08/02 05:24:47 scrappy Exp $
* *
* NOTES * NOTES
* ****************************** * ******************************
@@ -206,7 +206,7 @@ cat > $TABCFILE <<FuNkYfMgRtAbStUfF
* *
* *
* IDENTIFICATION * IDENTIFICATION
* $Header: /cvsroot/pgsql/src/backend/utils/Attic/Gen_fmgrtab.sh.in,v 1.15 1999/04/09 22:35:41 tgl Exp $ * $Header: /cvsroot/pgsql/src/backend/utils/Attic/Gen_fmgrtab.sh.in,v 1.15.2.1 1999/08/02 05:24:47 scrappy Exp $
* *
* NOTES * NOTES
* *
@@ -225,7 +225,7 @@ cat > $TABCFILE <<FuNkYfMgRtAbStUfF
*/ */
#include <string.h> #include <string.h>
#include <postgres.h> #include "postgres.h"
#include "utils/fmgrtab.h" #include "utils/fmgrtab.h"
FuNkYfMgRtAbStUfF FuNkYfMgRtAbStUfF

View File

@@ -4,7 +4,7 @@
# Makefile for utils/adt # Makefile for utils/adt
# #
# IDENTIFICATION # IDENTIFICATION
# $Header: /cvsroot/pgsql/src/backend/utils/adt/Makefile,v 1.21 1998/12/30 19:56:29 wieck Exp $ # $Header: /cvsroot/pgsql/src/backend/utils/adt/Makefile,v 1.21.2.1 1999/08/02 05:24:49 scrappy Exp $
# #
#------------------------------------------------------------------------- #-------------------------------------------------------------------------
@@ -13,6 +13,16 @@ include ../../../Makefile.global
CFLAGS += -I../.. CFLAGS += -I../..
# seems to be required for some date/time stuff 1999/07/22 bjm
ifeq ($(CPU),alpha)
ifeq ($(CC), gcc)
CFLAGS+= -mieee
endif
ifeq ($(CC), egcs)
CFLAGS+= -mieee
endif
endif
ifdef MULTIBYTE ifdef MULTIBYTE
CFLAGS+= $(MBFLAGS) CFLAGS+= $(MBFLAGS)
endif endif
@@ -40,4 +50,3 @@ clean:
ifeq (depend,$(wildcard depend)) ifeq (depend,$(wildcard depend))
include depend include depend
endif endif

View File

@@ -7,21 +7,20 @@
* *
* *
* IDENTIFICATION * IDENTIFICATION
* $Header: /cvsroot/pgsql/src/backend/utils/adt/acl.c,v 1.37 1999/07/09 03:28:51 momjian Exp $ * $Header: /cvsroot/pgsql/src/backend/utils/adt/acl.c,v 1.37.2.1 1999/08/02 05:24:49 scrappy Exp $
* *
*------------------------------------------------------------------------- *-------------------------------------------------------------------------
*/ */
#include <ctype.h> #include <ctype.h>
#include <string.h>
#include "postgres.h" #include "postgres.h"
#include <utils/memutils.h>
#include "utils/acl.h"
#include "utils/syscache.h"
#include "catalog/catalog.h" #include "catalog/catalog.h"
#include "catalog/pg_shadow.h" #include "catalog/pg_shadow.h"
#include "catalog/pg_type.h" #include "catalog/pg_type.h"
#include "miscadmin.h" #include "miscadmin.h"
#include "utils/acl.h"
#include "utils/memutils.h"
#include "utils/syscache.h"
static char *getid(char *s, char *n); static char *getid(char *s, char *n);
static int32 aclitemeq(AclItem *a1, AclItem *a2); static int32 aclitemeq(AclItem *a1, AclItem *a2);

View File

@@ -7,30 +7,25 @@
* *
* *
* IDENTIFICATION * IDENTIFICATION
* $Header: /cvsroot/pgsql/src/backend/utils/adt/arrayfuncs.c,v 1.43 1999/05/25 16:11:50 momjian Exp $ * $Header: /cvsroot/pgsql/src/backend/utils/adt/arrayfuncs.c,v 1.43.2.1 1999/08/02 05:24:49 scrappy Exp $
* *
*------------------------------------------------------------------------- *-------------------------------------------------------------------------
*/ */
#include <ctype.h> #include <ctype.h>
#include <stdio.h>
#include <string.h>
#include <stdarg.h>
#include "postgres.h" #include "postgres.h"
#include "catalog/catalog.h" #include "catalog/catalog.h"
#include "catalog/pg_type.h" #include "catalog/pg_type.h"
#include "utils/syscache.h"
#include "utils/memutils.h"
#include "storage/fd.h"
#include "fmgr.h" #include "fmgr.h"
#include "utils/array.h"
#include "utils/elog.h"
#include "libpq/libpq-fs.h"
#include "libpq/be-fsstubs.h" #include "libpq/be-fsstubs.h"
#include "libpq/libpq-fs.h"
#include "storage/fd.h"
#include "utils/array.h"
#include "utils/memutils.h"
#include "utils/syscache.h"
#define ASSGN "=" #define ASSGN "="
@@ -477,7 +472,7 @@ _ReadArrayStr(char *arrayStr,
if (values[i]) if (values[i])
{ {
if (typalign == 'd') if (typalign == 'd')
*nbytes += DOUBLEALIGN(*(int32 *) values[i]); *nbytes += MAXALIGN(*(int32 *) values[i]);
else else
*nbytes += INTALIGN(*(int32 *) values[i]); *nbytes += INTALIGN(*(int32 *) values[i]);
} }

View File

@@ -7,7 +7,7 @@
* *
* *
* IDENTIFICATION * IDENTIFICATION
* $Header: /cvsroot/pgsql/src/backend/utils/adt/arrayutils.c,v 1.7 1999/02/13 23:19:02 momjian Exp $ * $Header: /cvsroot/pgsql/src/backend/utils/adt/arrayutils.c,v 1.7.2.1 1999/08/02 05:24:50 scrappy Exp $
* *
*------------------------------------------------------------------------- *-------------------------------------------------------------------------
*/ */
@@ -15,9 +15,7 @@
#define WEAK_C_OPTIMIZER #define WEAK_C_OPTIMIZER
#include "postgres.h" #include "postgres.h"
#include "utils/array.h" #include "utils/array.h"
int int
GetOffset(int n, int *dim, int *lb, int *indx) GetOffset(int n, int *dim, int *lb, int *indx)
{ {

View File

@@ -7,16 +7,14 @@
* *
* *
* IDENTIFICATION * IDENTIFICATION
* $Header: /cvsroot/pgsql/src/backend/utils/adt/bool.c,v 1.16 1999/02/13 23:19:04 momjian Exp $ * $Header: /cvsroot/pgsql/src/backend/utils/adt/bool.c,v 1.16.2.1 1999/08/02 05:24:50 scrappy Exp $
* *
*------------------------------------------------------------------------- *-------------------------------------------------------------------------
*/ */
#include <string.h>
#include "postgres.h" #include "postgres.h"
#include "utils/builtins.h" /* where the declarations go */ #include "utils/builtins.h"
#include "utils/palloc.h"
/***************************************************************************** /*****************************************************************************
* USER I/O ROUTINES * * USER I/O ROUTINES *

View File

@@ -9,11 +9,9 @@
* workings can be found in the book "Software Solutions in C" by * workings can be found in the book "Software Solutions in C" by
* Dale Schumacher, Academic Press, ISBN: 0-12-632360-7. * Dale Schumacher, Academic Press, ISBN: 0-12-632360-7.
* *
* $Header: /cvsroot/pgsql/src/backend/utils/adt/cash.c,v 1.28 1999/05/25 16:11:52 momjian Exp $ * $Header: /cvsroot/pgsql/src/backend/utils/adt/cash.c,v 1.28.2.1 1999/08/02 05:24:50 scrappy Exp $
*/ */
#include <stdio.h>
#include <string.h>
#include <limits.h> #include <limits.h>
#include <ctype.h> #include <ctype.h>
#include <locale.h> #include <locale.h>
@@ -34,7 +32,6 @@ static const char *num_word(Cash value);
#ifdef USE_LOCALE #ifdef USE_LOCALE
static struct lconv *lconvert = NULL; static struct lconv *lconvert = NULL;
#endif #endif
/* cash_in() /* cash_in()

View File

@@ -8,15 +8,12 @@
* *
* *
* IDENTIFICATION * IDENTIFICATION
* $Header: /cvsroot/pgsql/src/backend/utils/adt/char.c,v 1.22 1999/05/25 16:11:53 momjian Exp $ * $Header: /cvsroot/pgsql/src/backend/utils/adt/char.c,v 1.22.2.1 1999/08/02 05:24:50 scrappy Exp $
* *
*------------------------------------------------------------------------- *-------------------------------------------------------------------------
*/ */
#include <stdio.h> /* for sprintf() */
#include <string.h>
#include "postgres.h" #include "postgres.h"
#include "utils/palloc.h" #include "utils/builtins.h"
#include "utils/builtins.h" /* where the declarations go */
/***************************************************************************** /*****************************************************************************
* USER I/O ROUTINES * * USER I/O ROUTINES *

View File

@@ -6,7 +6,7 @@
* *
* *
* IDENTIFICATION * IDENTIFICATION
* $Header: /cvsroot/pgsql/src/backend/utils/adt/Attic/chunk.c,v 1.20 1999/05/25 16:11:55 momjian Exp $ * $Header: /cvsroot/pgsql/src/backend/utils/adt/Attic/chunk.c,v 1.20.2.1 1999/08/02 05:24:50 scrappy Exp $
* *
*------------------------------------------------------------------------- *-------------------------------------------------------------------------
*/ */
@@ -15,21 +15,15 @@
#include <fcntl.h> #include <fcntl.h>
#include "postgres.h" #include "postgres.h"
#include "fmgr.h"
#include "catalog/pg_type.h" #include "catalog/pg_type.h"
#include "fmgr.h"
#include "libpq/be-fsstubs.h" #include "libpq/be-fsstubs.h"
#include "libpq/libpq-fs.h" #include "libpq/libpq-fs.h"
#include "optimizer/internal.h" #include "optimizer/internal.h"
#include "utils/array.h" #include "utils/array.h"
#include "utils/memutils.h" #include "utils/memutils.h"
#ifndef HAVE_MEMMOVE
#include <regex/utils.h>
#else
#include <string.h>
#endif
#define INFTY 500000000 #define INFTY 500000000
#define MANY 10000 #define MANY 10000
#define MAXPAT 20 #define MAXPAT 20

View File

@@ -9,7 +9,7 @@
* *
* *
* IDENTIFICATION * IDENTIFICATION
* $Header: /cvsroot/pgsql/src/backend/utils/adt/date.c,v 1.32 1999/05/25 16:11:56 momjian Exp $ * $Header: /cvsroot/pgsql/src/backend/utils/adt/date.c,v 1.32.2.1 1999/08/02 05:24:51 scrappy Exp $
* *
* NOTES * NOTES
* This code is actually (almost) unused. * This code is actually (almost) unused.
@@ -24,23 +24,21 @@
*------------------------------------------------------------------------- *-------------------------------------------------------------------------
*/ */
#include <ctype.h> #include <ctype.h>
#include <stdio.h>
#include <time.h> #include <time.h>
#include <sys/time.h> #include <sys/time.h>
#include <sys/types.h> #include <sys/types.h>
#include <string.h>
#include "postgres.h" #include "postgres.h"
#include "miscadmin.h"
#ifdef HAVE_FLOAT_H #ifdef HAVE_FLOAT_H
#include <float.h> #include <float.h>
#endif #endif
#ifdef HAVE_LIMITS_H #ifdef HAVE_LIMITS_H
#include <limits.h> #include <limits.h>
#endif #endif
#include "access/xact.h" #include "access/xact.h"
#include "utils/builtins.h" /* where function declarations go */ #include "miscadmin.h"
#include "utils/palloc.h" #include "utils/builtins.h"
#include "utils/dt.h" #include "utils/dt.h"
#define INVALID_RELTIME_STR "Undefined RelTime" #define INVALID_RELTIME_STR "Undefined RelTime"

View File

@@ -7,12 +7,10 @@
* *
* *
* IDENTIFICATION * IDENTIFICATION
* $Header: /cvsroot/pgsql/src/backend/utils/adt/datetime.c,v 1.33 1999/05/25 16:11:58 momjian Exp $ * $Header: /cvsroot/pgsql/src/backend/utils/adt/datetime.c,v 1.33.2.1 1999/08/02 05:24:51 scrappy Exp $
* *
*------------------------------------------------------------------------- *-------------------------------------------------------------------------
*/ */
#include <stdio.h> /* for sprintf() */
#include <string.h>
#include <limits.h> #include <limits.h>
#include "postgres.h" #include "postgres.h"
@@ -21,9 +19,6 @@
#endif #endif
#include "miscadmin.h" #include "miscadmin.h"
#include "utils/builtins.h" #include "utils/builtins.h"
#include "utils/nabstime.h"
#include "utils/datetime.h"
#include "access/xact.h"
static int date2tm(DateADT dateVal, int *tzp, struct tm * tm, double *fsec, char **tzn); static int date2tm(DateADT dateVal, int *tzp, struct tm * tm, double *fsec, char **tzn);

View File

@@ -6,7 +6,7 @@
* *
* *
* IDENTIFICATION * IDENTIFICATION
* $Header: /cvsroot/pgsql/src/backend/utils/adt/datum.c,v 1.12 1999/02/13 23:19:09 momjian Exp $ * $Header: /cvsroot/pgsql/src/backend/utils/adt/datum.c,v 1.12.2.1 1999/08/02 05:24:51 scrappy Exp $
* *
*------------------------------------------------------------------------- *-------------------------------------------------------------------------
*/ */
@@ -27,11 +27,8 @@
* particular instance of the type and about its value. * particular instance of the type and about its value.
* *
*/ */
#include <string.h>
#include "postgres.h" #include "postgres.h"
#include "utils/datum.h" #include "utils/datum.h"
#include "catalog/pg_type.h"
#include "utils/palloc.h"
/*------------------------------------------------------------------------- /*-------------------------------------------------------------------------
* datumGetSize * datumGetSize

View File

@@ -7,19 +7,16 @@
* *
* *
* IDENTIFICATION * IDENTIFICATION
* $Header: /cvsroot/pgsql/src/backend/utils/adt/Attic/dt.c,v 1.72 1999/07/08 03:22:46 momjian Exp $ * $Header: /cvsroot/pgsql/src/backend/utils/adt/Attic/dt.c,v 1.72.2.1 1999/08/02 05:24:51 scrappy Exp $
* *
*------------------------------------------------------------------------- *-------------------------------------------------------------------------
*/ */
#include <stdio.h>
#include <ctype.h> #include <ctype.h>
#include <math.h> #include <math.h>
#include <string.h>
#include <sys/types.h> #include <sys/types.h>
#include <errno.h> #include <errno.h>
#include "postgres.h" #include "postgres.h"
#include "miscadmin.h"
#ifdef HAVE_FLOAT_H #ifdef HAVE_FLOAT_H
#include <float.h> #include <float.h>
#endif #endif
@@ -29,8 +26,9 @@
#ifndef USE_POSIX_TIME #ifndef USE_POSIX_TIME
#include <sys/timeb.h> #include <sys/timeb.h>
#endif #endif
#include "utils/builtins.h"
#include "miscadmin.h"
#include "utils/builtins.h"
static int DecodeDate(char *str, int fmask, int *tmask, struct tm * tm); static int DecodeDate(char *str, int fmask, int *tmask, struct tm * tm);
static int DecodeNumber(int flen, char *field, static int DecodeNumber(int flen, char *field,

View File

@@ -7,20 +7,18 @@
* *
* *
* IDENTIFICATION * IDENTIFICATION
* $Header: /cvsroot/pgsql/src/backend/utils/adt/Attic/filename.c,v 1.17 1999/02/13 23:19:13 momjian Exp $ * $Header: /cvsroot/pgsql/src/backend/utils/adt/Attic/filename.c,v 1.17.2.1 1999/08/02 05:24:52 scrappy Exp $
* *
*------------------------------------------------------------------------- *-------------------------------------------------------------------------
*/ */
#include <string.h>
#include <stdio.h>
#include <pwd.h> #include <pwd.h>
#include <sys/param.h> #include <sys/param.h>
#include "postgres.h" #include "postgres.h"
#include <miscadmin.h> #include "miscadmin.h"
#include "utils/builtins.h" /* where function declarations go */ #include "utils/builtins.h"
char * char *
filename_in(char *file) filename_in(char *file)

View File

@@ -7,7 +7,7 @@
* *
* *
* IDENTIFICATION * IDENTIFICATION
* $Header: /cvsroot/pgsql/src/backend/utils/adt/float.c,v 1.42 1999/05/25 16:12:02 momjian Exp $ * $Header: /cvsroot/pgsql/src/backend/utils/adt/float.c,v 1.42.2.1 1999/08/02 05:24:52 scrappy Exp $
* *
*------------------------------------------------------------------------- *-------------------------------------------------------------------------
*/ */
@@ -45,10 +45,7 @@
* for calls to pow(), exp() since on some machines (my Linux box * for calls to pow(), exp() since on some machines (my Linux box
* included) these routines do not set errno. - tgl 97/05/10 * included) these routines do not set errno. - tgl 97/05/10
*/ */
#include <stdio.h> /* for sprintf() */
#include <string.h>
#include <ctype.h> #include <ctype.h>
#include <stdlib.h>
#include <errno.h> #include <errno.h>
#include <float.h> /* faked on sunos4 */ #include <float.h> /* faked on sunos4 */
@@ -60,8 +57,7 @@
#include <limits.h> #include <limits.h>
#endif #endif
#include "fmgr.h" #include "fmgr.h"
#include "utils/builtins.h" /* for ftod() prototype */ #include "utils/builtins.h"
#include "utils/palloc.h"
#ifndef NAN #ifndef NAN
#define NAN (0.0/0.0) #define NAN (0.0/0.0)
@@ -134,7 +130,7 @@ extern double rint(double x);
* until the distributions are updated. * until the distributions are updated.
* --djm 12/16/96 * --djm 12/16/96
*/ */
#if ( defined(linux) && defined(__alpha) ) && !defined(UNSAFE_FLOATS) #if ( defined(linux) && defined(__alpha__) ) && !defined(UNSAFE_FLOATS)
#define UNSAFE_FLOATS #define UNSAFE_FLOATS
#endif #endif

View File

@@ -7,22 +7,18 @@
* *
* *
* IDENTIFICATION * IDENTIFICATION
* $Header: /cvsroot/pgsql/src/backend/utils/adt/geo_ops.c,v 1.41 1999/02/21 03:49:30 scrappy Exp $ * $Header: /cvsroot/pgsql/src/backend/utils/adt/geo_ops.c,v 1.41.2.1 1999/08/02 05:24:52 scrappy Exp $
* *
*------------------------------------------------------------------------- *-------------------------------------------------------------------------
*/ */
#include <math.h> #include <math.h>
#include <limits.h> #include <limits.h>
#include <float.h> #include <float.h>
#include <stdio.h> /* for sprintf proto, etc. */
#include <stdlib.h> /* for strtod, etc. */
#include <string.h>
#include <ctype.h> #include <ctype.h>
#include "postgres.h" #include "postgres.h"
#include "utils/geo_decls.h" #include "utils/geo_decls.h"
#include "utils/palloc.h"
#ifndef PI #ifndef PI
#define PI 3.1415926536 #define PI 3.1415926536

View File

@@ -8,7 +8,7 @@
* *
* *
* IDENTIFICATION * IDENTIFICATION
* $Header: /cvsroot/pgsql/src/backend/utils/adt/geo_selfuncs.c,v 1.8 1999/03/28 01:56:12 tgl Exp $ * $Header: /cvsroot/pgsql/src/backend/utils/adt/geo_selfuncs.c,v 1.8.2.1 1999/08/02 05:24:53 scrappy Exp $
* *
* XXX These are totally bogus. * XXX These are totally bogus.
* *
@@ -16,9 +16,6 @@
*/ */
#include "postgres.h" #include "postgres.h"
#include "access/attnum.h"
#include "utils/geo_decls.h" /* where function declarations go */
#include "utils/palloc.h"
#include "utils/builtins.h" #include "utils/builtins.h"
float64 float64

View File

@@ -16,7 +16,7 @@
*/ */
#if defined(LIBC_SCCS) && !defined(lint) #if defined(LIBC_SCCS) && !defined(lint)
static const char rcsid[] = "$Id: inet_net_ntop.c,v 1.6 1999/05/25 16:12:04 momjian Exp $"; static const char rcsid[] = "$Id: inet_net_ntop.c,v 1.6.2.1 1999/08/02 05:24:53 scrappy Exp $";
#endif #endif
@@ -26,12 +26,9 @@ static const char rcsid[] = "$Id: inet_net_ntop.c,v 1.6 1999/05/25 16:12:04 momj
#include <arpa/inet.h> #include <arpa/inet.h>
#include <errno.h> #include <errno.h>
#include <stdio.h>
#include <string.h>
#include <stdlib.h>
#include <postgres.h> #include "postgres.h"
#include <utils/builtins.h> #include "utils/builtins.h"
#ifdef SPRINTF_CHAR #ifdef SPRINTF_CHAR
#define SPRINTF(x) strlen(sprintf/**/x) #define SPRINTF(x) strlen(sprintf/**/x)

View File

@@ -16,7 +16,7 @@
*/ */
#if defined(LIBC_SCCS) && !defined(lint) #if defined(LIBC_SCCS) && !defined(lint)
static const char rcsid[] = "$Id: inet_net_pton.c,v 1.8 1999/05/25 16:12:05 momjian Exp $"; static const char rcsid[] = "$Id: inet_net_pton.c,v 1.8.2.1 1999/08/02 05:24:53 scrappy Exp $";
#endif #endif
@@ -28,12 +28,9 @@ static const char rcsid[] = "$Id: inet_net_pton.c,v 1.8 1999/05/25 16:12:05 momj
#include <assert.h> #include <assert.h>
#include <ctype.h> #include <ctype.h>
#include <errno.h> #include <errno.h>
#include <stdio.h>
#include <string.h>
#include <stdlib.h>
#include <postgres.h> #include "postgres.h"
#include <utils/builtins.h> #include "utils/builtins.h"
#ifdef SPRINTF_CHAR #ifdef SPRINTF_CHAR
#define SPRINTF(x) strlen(sprintf/**/x) #define SPRINTF(x) strlen(sprintf/**/x)

View File

@@ -7,7 +7,7 @@
* *
* *
* IDENTIFICATION * IDENTIFICATION
* $Header: /cvsroot/pgsql/src/backend/utils/adt/int.c,v 1.21 1999/07/09 15:09:54 tgl Exp $ * $Header: /cvsroot/pgsql/src/backend/utils/adt/int.c,v 1.21.2.1 1999/08/02 05:24:53 scrappy Exp $
* *
*------------------------------------------------------------------------- *-------------------------------------------------------------------------
*/ */
@@ -28,15 +28,13 @@
* XXX makes massive and possibly unwarranted type promotion assumptions. * XXX makes massive and possibly unwarranted type promotion assumptions.
* fix me when we figure out what we want to do about ANSIfication... * fix me when we figure out what we want to do about ANSIfication...
*/ */
#include <stdio.h>
#include <string.h> #include "postgres.h"
#ifdef HAVE_LIMITS_H #ifdef HAVE_LIMITS_H
#include <limits.h> #include <limits.h>
#endif #endif
#include "postgres.h" #include "utils/builtins.h"
#include "fmgr.h"
#include "utils/builtins.h" /* where the declarations go */
#ifndef SHRT_MAX #ifndef SHRT_MAX
#define SHRT_MAX (0x7FFF) #define SHRT_MAX (0x7FFF)

View File

@@ -5,9 +5,6 @@
* *
*------------------------------------------------------------------------- *-------------------------------------------------------------------------
*/ */
#include <stdio.h> /* for sprintf proto, etc. */
#include <stdlib.h> /* for strtod, etc. */
#include <string.h>
#include <ctype.h> #include <ctype.h>
#include <time.h> #include <time.h>
#include <math.h> #include <math.h>
@@ -15,7 +12,6 @@
#include <limits.h> #include <limits.h>
#include "postgres.h" #include "postgres.h"
#include "utils/palloc.h"
#include "utils/int8.h" #include "utils/int8.h"
#define MAXINT8LEN 25 #define MAXINT8LEN 25

View File

@@ -17,11 +17,9 @@
* *
*------------------------------------------------------------------------- *-------------------------------------------------------------------------
*/ */
#include <string.h> #include "postgres.h"
#include "postgres.h" /* postgres system include file */
#include "utils/palloc.h"
#include "utils/builtins.h" /* where the function declarations go */
#include "mb/pg_wchar.h" #include "mb/pg_wchar.h"
#include "utils/builtins.h"
static int like(pg_wchar * text, pg_wchar * p); static int like(pg_wchar * text, pg_wchar * p);
@@ -111,7 +109,7 @@ textnlike(struct varlena * s, struct varlena * p)
} }
/* $Revision: 1.25 $ /* $Revision: 1.25.2.1 $
** "like.c" A first attempt at a LIKE operator for Postgres95. ** "like.c" A first attempt at a LIKE operator for Postgres95.
** **
** Originally written by Rich $alz, mirror!rs, Wed Nov 26 19:03:17 EST 1986. ** Originally written by Rich $alz, mirror!rs, Wed Nov 26 19:03:17 EST 1986.

View File

@@ -1,16 +1,12 @@
/* /*
* PostgreSQL type definitions for MAC addresses. * PostgreSQL type definitions for MAC addresses.
* *
* $Id: mac.c,v 1.8 1999/05/25 16:12:08 momjian Exp $ * $Id: mac.c,v 1.8.2.1 1999/08/02 05:24:54 scrappy Exp $
*/ */
#include <stdio.h>
#include <string.h>
#include <postgres.h> #include "postgres.h"
#include <utils/palloc.h> #include "utils/builtins.h"
#include <utils/builtins.h>
#include <utils/inet.h>
manufacturer manufacturers[] = { manufacturer manufacturers[] = {
{0x00, 0x00, 0x0C, "Cisco"}, {0x00, 0x00, 0x0C, "Cisco"},

View File

@@ -7,7 +7,7 @@
* *
* *
* IDENTIFICATION * IDENTIFICATION
* $Header: /cvsroot/pgsql/src/backend/utils/adt/misc.c,v 1.16 1999/02/13 23:19:23 momjian Exp $ * $Header: /cvsroot/pgsql/src/backend/utils/adt/misc.c,v 1.16.2.1 1999/08/02 05:24:54 scrappy Exp $
* *
*------------------------------------------------------------------------- *-------------------------------------------------------------------------
*/ */
@@ -15,8 +15,6 @@
#include <sys/file.h> #include <sys/file.h>
#include <time.h> #include <time.h>
#include "postgres.h" #include "postgres.h"
#include "utils/datum.h"
#include "catalog/pg_type.h"
#include "utils/builtins.h" #include "utils/builtins.h"
/*------------------------------------------------------------------------- /*-------------------------------------------------------------------------

View File

@@ -4,16 +4,13 @@
* *
* Copyright (c) 1994, Regents of the University of California * Copyright (c) 1994, Regents of the University of California
* *
* $Id: nabstime.c,v 1.55 1999/05/25 16:12:09 momjian Exp $ * $Id: nabstime.c,v 1.55.2.1 1999/08/02 05:24:54 scrappy Exp $
* *
*/ */
#include <stdio.h>
#include <ctype.h> #include <ctype.h>
#include <string.h>
#include <sys/types.h> #include <sys/types.h>
#include "postgres.h" #include "postgres.h"
#include <miscadmin.h>
#ifdef HAVE_FLOAT_H #ifdef HAVE_FLOAT_H
#include <float.h> #include <float.h>
#endif #endif
@@ -23,8 +20,10 @@
#ifndef USE_POSIX_TIME #ifndef USE_POSIX_TIME
#include <sys/timeb.h> #include <sys/timeb.h>
#endif #endif
#include "utils/builtins.h"
#include "access/xact.h" #include "access/xact.h"
#include "miscadmin.h"
#include "utils/builtins.h"
static AbsoluteTime tm2abstime(struct tm * tm, int tz); static AbsoluteTime tm2abstime(struct tm * tm, int tz);
@@ -348,8 +347,6 @@ nabstimeout(AbsoluteTime time)
break; break;
default: default:
abstime2tm(time, &tz, tm, tzn); abstime2tm(time, &tz, tm, tzn);
#if DATEDEBUG
#endif
EncodeDateTime(tm, fsec, &tz, &tzn, DateStyle, buf); EncodeDateTime(tm, fsec, &tz, &tzn, DateStyle, buf);
break; break;
} }

View File

@@ -11,14 +11,12 @@
* *
* *
* IDENTIFICATION * IDENTIFICATION
* $Header: /cvsroot/pgsql/src/backend/utils/adt/name.c,v 1.18 1999/05/25 16:12:10 momjian Exp $ * $Header: /cvsroot/pgsql/src/backend/utils/adt/name.c,v 1.18.2.1 1999/08/02 05:24:55 scrappy Exp $
* *
*------------------------------------------------------------------------- *-------------------------------------------------------------------------
*/ */
#include <string.h>
#include "postgres.h" #include "postgres.h"
#include "utils/builtins.h" /* where the declarations go */ #include "utils/builtins.h"
#include "utils/palloc.h" /* where the declarations go */
/***************************************************************************** /*****************************************************************************
* USER I/O ROUTINES (none) * * USER I/O ROUTINES (none) *

View File

@@ -3,24 +3,20 @@
* is for IP V4 CIDR notation, but prepared for V6: just * is for IP V4 CIDR notation, but prepared for V6: just
* add the necessary bits where the comments indicate. * add the necessary bits where the comments indicate.
* *
* $Id: network.c,v 1.10 1999/06/02 03:37:15 momjian Exp $ * $Id: network.c,v 1.10.2.1 1999/08/02 05:24:55 scrappy Exp $
* Jon Postel RIP 16 Oct 1998 * Jon Postel RIP 16 Oct 1998
*/ */
#include <sys/types.h> #include <sys/types.h>
#include <sys/socket.h> #include <sys/socket.h>
#include <stdio.h>
#include <string.h>
#include <errno.h> #include <errno.h>
#include <netinet/in.h> #include <netinet/in.h>
#include <arpa/inet.h> #include <arpa/inet.h>
#include <postgres.h> #include "postgres.h"
#include <utils/palloc.h> #include "utils/builtins.h"
#include <utils/builtins.h>
#include <utils/inet.h>
static int v4bitncmp(unsigned int a1, unsigned int a2, int bits); static int v4bitncmp(unsigned int a1, unsigned int a2, int bits);

View File

@@ -7,7 +7,7 @@
* *
* *
* IDENTIFICATION * IDENTIFICATION
* $Header: /cvsroot/pgsql/src/backend/utils/adt/Attic/not_in.c,v 1.16 1999/05/25 16:12:12 momjian Exp $ * $Header: /cvsroot/pgsql/src/backend/utils/adt/Attic/not_in.c,v 1.16.2.1 1999/08/02 05:24:55 scrappy Exp $
* *
*------------------------------------------------------------------------- *-------------------------------------------------------------------------
*/ */
@@ -22,12 +22,10 @@
* columns are ******REALLY****** implemented!!!!!!!!!!! * columns are ******REALLY****** implemented!!!!!!!!!!!
* *
*/ */
#include <stdio.h>
#include <string.h>
#include "postgres.h" #include "postgres.h"
#include "access/heapam.h" #include "access/heapam.h"
#include "access/relscan.h" #include "utils/builtins.h"
#include "utils/builtins.h" /* where function decls go */
static int my_varattno(Relation rd, char *a); static int my_varattno(Relation rd, char *a);

View File

@@ -5,14 +5,11 @@
* *
* 1998 Jan Wieck * 1998 Jan Wieck
* *
* $Header: /cvsroot/pgsql/src/backend/utils/adt/numeric.c,v 1.16 1999/05/25 22:42:13 momjian Exp $ * $Header: /cvsroot/pgsql/src/backend/utils/adt/numeric.c,v 1.16.2.1 1999/08/02 05:24:55 scrappy Exp $
* *
* ---------- * ----------
*/ */
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <ctype.h> #include <ctype.h>
#include <float.h> #include <float.h>
#include <math.h> #include <math.h>
@@ -21,10 +18,8 @@
#include "postgres.h" #include "postgres.h"
#include "utils/builtins.h" #include "utils/builtins.h"
#include "utils/palloc.h"
#include "utils/numeric.h" #include "utils/numeric.h"
/* ---------- /* ----------
* Uncomment the following to enable compilation of dump_numeric() * Uncomment the following to enable compilation of dump_numeric()
* and dump_var() and to get a dump of any result produced by make_result(). * and dump_var() and to get a dump of any result produced by make_result().

View File

@@ -10,23 +10,18 @@
* *
* *
* IDENTIFICATION * IDENTIFICATION
* $Header: /cvsroot/pgsql/src/backend/utils/adt/numutils.c,v 1.34 1999/07/10 17:03:33 momjian Exp $ * $Header: /cvsroot/pgsql/src/backend/utils/adt/numutils.c,v 1.34.2.1 1999/08/02 05:24:56 scrappy Exp $
* *
*------------------------------------------------------------------------- *-------------------------------------------------------------------------
*/ */
#include <stdio.h> /* for sprintf() */
#include <errno.h> #include <errno.h>
#include <math.h> #include <math.h>
#include "postgres.h"
#ifdef HAVE_LIMITS_H #ifdef HAVE_LIMITS_H
#include <limits.h> #include <limits.h>
#endif #endif
#include "postgres.h" #include "utils/builtins.h"
#include "utils/builtins.h" /* where the declarations go */
#ifndef HAVE_MEMMOVE
#include <regex/utils.h>
#else
#include <string.h>
#endif
#ifndef INT_MAX #ifndef INT_MAX
#define INT_MAX (0x7FFFFFFFL) #define INT_MAX (0x7FFFFFFFL)

View File

@@ -7,16 +7,14 @@
* *
* *
* IDENTIFICATION * IDENTIFICATION
* $Header: /cvsroot/pgsql/src/backend/utils/adt/oid.c,v 1.23 1999/05/10 00:45:59 momjian Exp $ * $Header: /cvsroot/pgsql/src/backend/utils/adt/oid.c,v 1.23.2.1 1999/08/02 05:24:56 scrappy Exp $
* *
*------------------------------------------------------------------------- *-------------------------------------------------------------------------
*/ */
#include <stdio.h>
#include <string.h>
#include "postgres.h" #include "postgres.h"
#include "utils/builtins.h" /* where function declarations go */ #include "utils/builtins.h"
/***************************************************************************** /*****************************************************************************
* USER I/O ROUTINES * * USER I/O ROUTINES *

View File

@@ -1,7 +1,7 @@
/* /*
* Edmund Mergl <E.Mergl@bawue.de> * Edmund Mergl <E.Mergl@bawue.de>
* *
* $Id: oracle_compat.c,v 1.18 1999/05/26 12:56:00 momjian Exp $ * $Id: oracle_compat.c,v 1.18.2.1 1999/08/02 05:24:56 scrappy Exp $
* *
*/ */
@@ -9,7 +9,6 @@
#include <ctype.h> #include <ctype.h>
#include "postgres.h" #include "postgres.h"
text *lower(text *string); text *lower(text *string);
text *upper(text *string); text *upper(text *string);
text *initcap(text *string); text *initcap(text *string);

View File

@@ -7,7 +7,7 @@
* *
* *
* IDENTIFICATION * IDENTIFICATION
* $Header: /cvsroot/pgsql/src/backend/utils/adt/regexp.c,v 1.22 1999/02/13 23:19:30 momjian Exp $ * $Header: /cvsroot/pgsql/src/backend/utils/adt/regexp.c,v 1.22.2.1 1999/08/02 05:24:56 scrappy Exp $
* *
* Alistair Crooks added the code for the regex caching * Alistair Crooks added the code for the regex caching
* agc - cached the regular expressions used - there's a good chance * agc - cached the regular expressions used - there's a good chance
@@ -27,12 +27,11 @@
* *
*------------------------------------------------------------------------- *-------------------------------------------------------------------------
*/ */
#include <string.h> #include "postgres.h"
#include "postgres.h" /* postgres system include file */
#include <regex/regex.h>
#include "utils/builtins.h" /* where the function declarations go */ #include "regex/regex.h"
#include "utils/builtins.h"
#if defined(DISABLE_XOPEN_NLS) #if defined(DISABLE_XOPEN_NLS)
#undef _XOPEN_SOURCE #undef _XOPEN_SOURCE

View File

@@ -7,27 +7,21 @@
* *
* *
* IDENTIFICATION * IDENTIFICATION
* $Header: /cvsroot/pgsql/src/backend/utils/adt/regproc.c,v 1.37 1999/05/25 16:12:17 momjian Exp $ * $Header: /cvsroot/pgsql/src/backend/utils/adt/regproc.c,v 1.37.2.1 1999/08/02 05:24:57 scrappy Exp $
* *
*------------------------------------------------------------------------- *-------------------------------------------------------------------------
*/ */
#include <string.h>
#include "postgres.h" #include "postgres.h"
#include "miscadmin.h"
#include "access/heapam.h"
#include "access/genam.h"
#include "access/itup.h"
#include "access/relscan.h"
#include "storage/bufmgr.h"
#include "fmgr.h"
#include "utils/palloc.h"
#include "utils/syscache.h"
#include "access/genam.h"
#include "access/heapam.h"
#include "catalog/catname.h" #include "catalog/catname.h"
#include "catalog/indexing.h" #include "catalog/indexing.h"
#include "catalog/pg_proc.h" #include "catalog/pg_proc.h"
#include "catalog/pg_type.h" #include "catalog/pg_type.h"
#include "utils/builtins.h" /* where function declarations go */ #include "miscadmin.h"
#include "utils/builtins.h"
#include "utils/syscache.h"
/***************************************************************************** /*****************************************************************************
* USER I/O ROUTINES * * USER I/O ROUTINES *

View File

@@ -3,7 +3,7 @@
* out of it's tuple * out of it's tuple
* *
* IDENTIFICATION * IDENTIFICATION
* $Header: /cvsroot/pgsql/src/backend/utils/adt/ruleutils.c,v 1.18 1999/06/02 11:52:28 wieck Exp $ * $Header: /cvsroot/pgsql/src/backend/utils/adt/ruleutils.c,v 1.18.2.1 1999/08/02 05:24:57 scrappy Exp $
* *
* This software is copyrighted by Jan Wieck - Hamburg. * This software is copyrighted by Jan Wieck - Hamburg.
* *
@@ -35,27 +35,15 @@
* *
**********************************************************************/ **********************************************************************/
#include <stdio.h>
#include <stdlib.h>
#include <stdarg.h>
#include <unistd.h> #include <unistd.h>
#include <fcntl.h> #include <fcntl.h>
#include <string.h>
#include "postgres.h"
#include "executor/spi.h" #include "executor/spi.h"
#include "commands/trigger.h"
#include "utils/elog.h"
#include "utils/builtins.h"
#include "nodes/nodes.h"
#include "optimizer/clauses.h" #include "optimizer/clauses.h"
#include "utils/syscache.h"
#include "utils/lsyscache.h" #include "utils/lsyscache.h"
#include "catalog/pg_class.h"
#include "catalog/pg_type.h"
#include "catalog/pg_shadow.h" #include "catalog/pg_shadow.h"
#include "catalog/pg_index.h" #include "catalog/pg_index.h"
#include "catalog/pg_opclass.h"
#include "fmgr.h"
#define BUFSIZE 8192 #define BUFSIZE 8192

View File

@@ -12,25 +12,19 @@
* *
* *
* IDENTIFICATION * IDENTIFICATION
* $Header: /cvsroot/pgsql/src/backend/utils/adt/selfuncs.c,v 1.30 1999/06/19 00:44:44 tgl Exp $ * $Header: /cvsroot/pgsql/src/backend/utils/adt/selfuncs.c,v 1.30.2.1 1999/08/02 05:24:57 scrappy Exp $
* *
*------------------------------------------------------------------------- *-------------------------------------------------------------------------
*/ */
#include <stdio.h>
#include <string.h>
#include "postgres.h" #include "postgres.h"
#include "access/heapam.h" #include "access/heapam.h"
#include "fmgr.h"
#include "utils/builtins.h" /* for textout() prototype and where the
* declarations go */
#include "utils/palloc.h"
#include "catalog/catname.h" #include "catalog/catname.h"
#include "utils/syscache.h"
#include "utils/lsyscache.h" /* for get_oprrest() */
#include "catalog/pg_statistic.h" #include "catalog/pg_statistic.h"
#include "utils/builtins.h"
#include "utils/lsyscache.h"
#include "utils/syscache.h"
/* N is not a valid var/constant or relation id */ /* N is not a valid var/constant or relation id */
#define NONVALUE(N) ((N) == -1) #define NONVALUE(N) ((N) == -1)

View File

@@ -9,27 +9,19 @@
* *
* *
* IDENTIFICATION * IDENTIFICATION
* $Header: /cvsroot/pgsql/src/backend/utils/adt/Attic/sets.c,v 1.21 1999/02/13 23:19:33 momjian Exp $ * $Header: /cvsroot/pgsql/src/backend/utils/adt/Attic/sets.c,v 1.21.2.1 1999/08/02 05:24:57 scrappy Exp $
* *
*------------------------------------------------------------------------- *-------------------------------------------------------------------------
*/ */
#include <stdio.h> /* for sprintf() */
#include <string.h>
#include "postgres.h" #include "postgres.h"
#include "access/heapam.h" #include "access/heapam.h"
#include "access/relscan.h" #include "catalog/catname.h"
#include "access/xact.h" #include "catalog/indexing.h"
#include "catalog/pg_proc.h" /* for Form_pg_proc */ #include "catalog/pg_proc.h"
#include "catalog/catname.h" /* for ProcedureRelationName */ #include "utils/sets.h"
#include "catalog/indexing.h" /* for Num_pg_proc_indices */ #include "utils/syscache.h"
#include "fmgr.h"
#include "storage/lmgr.h"
#include "tcop/dest.h"
#include "utils/sets.h" /* for GENERICSETNAME */
#include "utils/syscache.h" /* for PROOID */
#include "utils/tqual.h"
extern CommandDest whereToSendOutput; /* defined in tcop/postgres.c */ extern CommandDest whereToSendOutput; /* defined in tcop/postgres.c */

View File

@@ -7,21 +7,16 @@
* *
* *
* IDENTIFICATION * IDENTIFICATION
* $Header: /cvsroot/pgsql/src/backend/utils/adt/tid.c,v 1.6 1999/02/13 23:19:34 momjian Exp $ * $Header: /cvsroot/pgsql/src/backend/utils/adt/tid.c,v 1.6.2.1 1999/08/02 05:24:57 scrappy Exp $
* *
* NOTES * NOTES
* input routine largely stolen from boxin(). * input routine largely stolen from boxin().
* *
*------------------------------------------------------------------------- *-------------------------------------------------------------------------
*/ */
#include <stdio.h> /* for sprintf() */
#include <string.h>
#include "postgres.h" #include "postgres.h"
#include "storage/bufpage.h" #include "utils/builtins.h"
#include "utils/palloc.h"
#include "utils/builtins.h" /* where function declarations go */
#define LDELIM '(' #define LDELIM '('
#define RDELIM ')' #define RDELIM ')'

View File

@@ -1,11 +1,10 @@
#include <stdio.h>
#include <string.h>
#include <time.h> #include <time.h>
#include <ctype.h> #include <ctype.h>
#include "postgres.h" #include "postgres.h"
#include "access/xact.h"
#include "miscadmin.h" #include "miscadmin.h"
#include "utils/builtins.h" #include "utils/builtins.h"
#include "access/xact.h"
time_t time_t
timestamp_in(const char *timestamp_str) timestamp_in(const char *timestamp_str)

View File

@@ -7,24 +7,24 @@
* *
* *
* IDENTIFICATION * IDENTIFICATION
* $Header: /cvsroot/pgsql/src/backend/utils/adt/varchar.c,v 1.48 1999/07/04 04:56:00 momjian Exp $ * $Header: /cvsroot/pgsql/src/backend/utils/adt/varchar.c,v 1.48.2.1 1999/08/02 05:24:58 scrappy Exp $
* *
*------------------------------------------------------------------------- *-------------------------------------------------------------------------
*/ */
#include <stdio.h> /* for sprintf() */
#include <string.h>
#include "postgres.h" #include "postgres.h"
#include "access/htup.h" #include "access/htup.h"
#include "utils/array.h"
#include "utils/builtins.h"
#include "catalog/pg_type.h" #include "catalog/pg_type.h"
#include "utils/builtins.h"
#ifdef MULTIBYTE
#include "mb/pg_wchar.h"
#endif
#ifdef CYR_RECODE #ifdef CYR_RECODE
char *convertstr(char *, int, int); char *convertstr(char *, int, int);
#endif #endif
#include "mb/pg_wchar.h"
/* /*
* CHAR() and VARCHAR() types are part of the ANSI SQL standard. CHAR() * CHAR() and VARCHAR() types are part of the ANSI SQL standard. CHAR()

View File

@@ -7,18 +7,16 @@
* *
* *
* IDENTIFICATION * IDENTIFICATION
* $Header: /cvsroot/pgsql/src/backend/utils/adt/varlena.c,v 1.48 1999/05/25 16:12:21 momjian Exp $ * $Header: /cvsroot/pgsql/src/backend/utils/adt/varlena.c,v 1.48.2.1 1999/08/02 05:24:58 scrappy Exp $
* *
*------------------------------------------------------------------------- *-------------------------------------------------------------------------
*/ */
#include <ctype.h> #include <ctype.h>
#include <string.h>
#include "postgres.h" #include "postgres.h"
#include "utils/palloc.h"
#include "utils/builtins.h" /* where function declarations go */
#include "mb/pg_wchar.h" #include "mb/pg_wchar.h"
#include "utils/builtins.h"
static int text_cmp(text *arg1, text *arg2); static int text_cmp(text *arg1, text *arg2);

View File

@@ -5,12 +5,11 @@
* *
* IDENTIFICATION * IDENTIFICATION
* *
* $Header: /cvsroot/pgsql/src/backend/utils/adt/version.c,v 1.6 1999/04/06 15:35:36 thomas Exp $ * $Header: /cvsroot/pgsql/src/backend/utils/adt/version.c,v 1.6.2.1 1999/08/02 05:24:58 scrappy Exp $
* *
*------------------------------------------------------------------------- *-------------------------------------------------------------------------
*/ */
#include <string.h>
#include "postgres.h" #include "postgres.h"
#include "version.h" #include "version.h"

View File

@@ -7,28 +7,18 @@
* *
* *
* IDENTIFICATION * IDENTIFICATION
* $Header: /cvsroot/pgsql/src/backend/utils/cache/catcache.c,v 1.43 1999/06/04 02:19:45 tgl Exp $ * $Header: /cvsroot/pgsql/src/backend/utils/cache/catcache.c,v 1.43.2.1 1999/08/02 05:24:59 scrappy Exp $
* *
*------------------------------------------------------------------------- *-------------------------------------------------------------------------
*/ */
#include <string.h>
#include "postgres.h" #include "postgres.h"
#include "access/heapam.h"
#include "access/genam.h" #include "access/genam.h"
#include "utils/tqual.h" #include "access/heapam.h"
#include "utils/builtins.h"
#include "utils/portal.h"
#include "utils/catcache.h"
#include "utils/elog.h"
#include "utils/palloc.h"
#include "utils/mcxt.h"
#include "utils/rel.h"
#include "storage/bufpage.h"
#include "access/valid.h" #include "access/valid.h"
#include "catalog/pg_type.h"
#include "miscadmin.h" #include "miscadmin.h"
#include "fmgr.h" /* for F_BOOLEQ, etc. DANGER */ #include "utils/builtins.h"
#include "catalog/pg_type.h" /* for OID of int28 type */ #include "utils/catcache.h"
#include "lib/dllist.h"
static void CatCacheRemoveCTup(CatCache *cache, Dlelem *e); static void CatCacheRemoveCTup(CatCache *cache, Dlelem *e);
static Index CatalogCacheComputeHashIndex(struct catcache * cacheInP); static Index CatalogCacheComputeHashIndex(struct catcache * cacheInP);

View File

@@ -7,7 +7,7 @@
* *
* *
* IDENTIFICATION * IDENTIFICATION
* $Header: /cvsroot/pgsql/src/backend/utils/cache/inval.c,v 1.23 1999/05/25 16:12:23 momjian Exp $ * $Header: /cvsroot/pgsql/src/backend/utils/cache/inval.c,v 1.23.2.1 1999/08/02 05:25:00 scrappy Exp $
* *
* Note - this code is real crufty... * Note - this code is real crufty...
* *
@@ -15,22 +15,14 @@
*/ */
#include "postgres.h" #include "postgres.h"
#include <miscadmin.h>
#include "access/heapam.h" /* XXX to support hacks below */
#include "access/htup.h"
#include "catalog/catalog.h" #include "catalog/catalog.h"
#include "catalog/catname.h"
#include "catalog/heap.h" #include "catalog/heap.h"
#include "storage/bufpage.h" #include "miscadmin.h"
#include "storage/buf.h" /* XXX for InvalidBuffer */
#include "storage/ipc.h"
#include "storage/sinval.h" #include "storage/sinval.h"
#include "utils/catcache.h" #include "utils/catcache.h"
#include "utils/inval.h" #include "utils/inval.h"
#include "utils/rel.h"
#include "utils/relcache.h" #include "utils/relcache.h"
#include "catalog/catname.h" /* XXX to support hacks below */
#include "utils/syscache.h" /* XXX to support the hacks below */
static InvalidationEntry InvalidationEntryAllocate(uint16 size); static InvalidationEntry InvalidationEntryAllocate(uint16 size);
static void LocalInvalidInvalidate(LocalInvalid invalid, void (*function) ()); static void LocalInvalidInvalidate(LocalInvalid invalid, void (*function) ());

View File

@@ -7,28 +7,19 @@
* *
* *
* IDENTIFICATION * IDENTIFICATION
* $Header: /cvsroot/pgsql/src/backend/utils/cache/lsyscache.c,v 1.27 1999/05/29 01:45:21 tgl Exp $ * $Header: /cvsroot/pgsql/src/backend/utils/cache/lsyscache.c,v 1.27.2.1 1999/08/02 05:25:00 scrappy Exp $
* *
* NOTES * NOTES
* Eventually, the index information should go through here, too. * Eventually, the index information should go through here, too.
*------------------------------------------------------------------------- *-------------------------------------------------------------------------
*/ */
#include <string.h>
#include "postgres.h" #include "postgres.h"
#include "nodes/pg_list.h"
#include "utils/syscache.h"
#include "utils/lsyscache.h"
#include "access/tupmacs.h"
#include "utils/rel.h"
#include "utils/palloc.h"
#include "utils/elog.h"
#include "access/attnum.h"
#include "access/heapam.h"
#include "catalog/pg_amop.h"
#include "catalog/pg_operator.h" #include "catalog/pg_operator.h"
#include "catalog/pg_type.h" #include "catalog/pg_type.h"
#include "utils/lsyscache.h"
#include "utils/syscache.h"
/* ---------- AMOP CACHES ---------- */ /* ---------- AMOP CACHES ---------- */

View File

@@ -7,18 +7,14 @@
* *
* *
* IDENTIFICATION * IDENTIFICATION
* $Header: /cvsroot/pgsql/src/backend/utils/cache/Attic/rel.c,v 1.5 1999/05/25 16:12:23 momjian Exp $ * $Header: /cvsroot/pgsql/src/backend/utils/cache/Attic/rel.c,v 1.5.2.1 1999/08/02 05:25:00 scrappy Exp $
* *
*------------------------------------------------------------------------- *-------------------------------------------------------------------------
*/ */
/* #define RELREFDEBUG 1 */ /* #define RELREFDEBUG 1 */
#include "postgres.h" #include "postgres.h"
#include "miscadmin.h"
#include "access/istrat.h" #include "access/istrat.h"
#include "access/tupdesc.h"
#include "utils/rel.h"
#include "storage/fd.h"
/* /*

View File

@@ -7,7 +7,7 @@
* *
* *
* IDENTIFICATION * IDENTIFICATION
* $Header: /cvsroot/pgsql/src/backend/utils/cache/relcache.c,v 1.62 1999/05/25 16:12:23 momjian Exp $ * $Header: /cvsroot/pgsql/src/backend/utils/cache/relcache.c,v 1.62.2.1 1999/08/02 05:25:01 scrappy Exp $
* *
*------------------------------------------------------------------------- *-------------------------------------------------------------------------
*/ */
@@ -30,54 +30,32 @@
* *
*/ */
#include <sys/types.h> #include <sys/types.h>
#include <stdio.h> /* for sprintf() */
#include <errno.h> #include <errno.h>
#include <sys/file.h> #include <sys/file.h>
#include <fcntl.h> #include <fcntl.h>
#include <string.h>
#include "postgres.h" #include "postgres.h"
#include "access/genam.h" #include "access/genam.h"
#include "access/heapam.h" #include "access/heapam.h"
#include "access/htup.h"
#include "access/istrat.h" #include "access/istrat.h"
#include "access/itup.h"
#include "access/skey.h"
#include "access/tupdesc.h"
#include "access/tupmacs.h"
#include "access/xact.h"
#include "catalog/catalog.h" #include "catalog/catalog.h"
#include "catalog/catname.h" #include "catalog/catname.h"
#include "catalog/index.h" #include "catalog/index.h"
#include "catalog/indexing.h" #include "catalog/indexing.h"
#include "catalog/pg_aggregate.h"
#include "catalog/pg_attrdef.h" #include "catalog/pg_attrdef.h"
#include "catalog/pg_attribute.h"
#include "catalog/pg_index.h"
#include "catalog/pg_proc.h"
#include "catalog/pg_class.h"
#include "catalog/pg_log.h" #include "catalog/pg_log.h"
#include "catalog/pg_proc.h"
#include "catalog/pg_relcheck.h" #include "catalog/pg_relcheck.h"
#include "catalog/pg_rewrite.h" #include "catalog/pg_rewrite.h"
#include "catalog/pg_type.h" #include "catalog/pg_type.h"
#include "catalog/pg_variable.h" #include "catalog/pg_variable.h"
#include "fmgr.h"
#include "lib/hasht.h" #include "lib/hasht.h"
#include "miscadmin.h" #include "miscadmin.h"
#include "storage/buf.h"
#include "storage/bufmgr.h"
#include "storage/fd.h" /* for SEEK_ */
#include "storage/lmgr.h"
#include "storage/smgr.h" #include "storage/smgr.h"
#include "utils/builtins.h" #include "utils/builtins.h"
#include "utils/catcache.h" #include "utils/catcache.h"
#include "utils/hsearch.h"
#include "utils/mcxt.h"
#include "utils/memutils.h"
#include "utils/rel.h"
#include "utils/relcache.h" #include "utils/relcache.h"
#include "utils/syscache.h"
static void RelationFlushRelation(Relation *relationPtr, static void RelationFlushRelation(Relation *relationPtr,

View File

@@ -7,7 +7,7 @@
* *
* *
* IDENTIFICATION * IDENTIFICATION
* $Header: /cvsroot/pgsql/src/backend/utils/cache/syscache.c,v 1.28 1999/07/07 16:09:33 momjian Exp $ * $Header: /cvsroot/pgsql/src/backend/utils/cache/syscache.c,v 1.28.2.1 1999/08/02 05:25:01 scrappy Exp $
* *
* NOTES * NOTES
* These routines allow the parser/planner/executor to perform * These routines allow the parser/planner/executor to perform
@@ -20,33 +20,21 @@
#include "postgres.h" #include "postgres.h"
#include "access/heapam.h" #include "access/heapam.h"
#include "access/htup.h"
#include "catalog/catname.h" #include "catalog/catname.h"
#include "utils/catcache.h" #include "catalog/pg_aggregate.h"
#include <string.h>
/* ----------------
* hardwired attribute information comes from system catalog files.
* ----------------
*/
#include "catalog/pg_am.h"
#include "catalog/pg_amop.h" #include "catalog/pg_amop.h"
#include "catalog/pg_attribute.h"
#include "catalog/pg_group.h" #include "catalog/pg_group.h"
#include "catalog/pg_index.h" #include "catalog/pg_index.h"
#include "catalog/pg_inherits.h" #include "catalog/pg_inherits.h"
#include "catalog/pg_language.h" #include "catalog/pg_language.h"
#include "catalog/pg_listener.h"
#include "catalog/pg_opclass.h" #include "catalog/pg_opclass.h"
#include "catalog/pg_operator.h" #include "catalog/pg_operator.h"
#include "catalog/pg_proc.h" #include "catalog/pg_proc.h"
#include "catalog/pg_class.h"
#include "catalog/pg_type.h"
#include "catalog/pg_rewrite.h" #include "catalog/pg_rewrite.h"
#include "catalog/pg_aggregate.h"
#include "catalog/pg_shadow.h" #include "catalog/pg_shadow.h"
#include "storage/large_object.h" #include "catalog/pg_type.h"
#include "catalog/pg_listener.h" #include "utils/catcache.h"
extern bool AMI_OVERRIDE; /* XXX style */ extern bool AMI_OVERRIDE; /* XXX style */

View File

@@ -7,7 +7,7 @@
* *
* *
* IDENTIFICATION * IDENTIFICATION
* $Header: /cvsroot/pgsql/src/backend/utils/cache/Attic/temprel.c,v 1.6 1999/07/03 15:43:57 momjian Exp $ * $Header: /cvsroot/pgsql/src/backend/utils/cache/Attic/temprel.c,v 1.6.2.1 1999/08/02 05:25:01 scrappy Exp $
* *
*------------------------------------------------------------------------- *-------------------------------------------------------------------------
*/ */
@@ -22,20 +22,12 @@
*/ */
#include <sys/types.h> #include <sys/types.h>
#include <stdio.h>
#include <string.h>
#include "postgres.h" #include "postgres.h"
#include "miscadmin.h"
#include "nodes/pg_list.h"
#include "utils/mcxt.h"
#include "utils/temprel.h"
#include "access/xact.h"
#include "access/htup.h"
#include "access/heapam.h" #include "access/heapam.h"
#include "catalog/heap.h" #include "catalog/heap.h"
#include "catalog/index.h" #include "catalog/index.h"
#include "catalog/pg_class.h" #include "utils/temprel.h"
GlobalMemory CacheCxt; GlobalMemory CacheCxt;

View File

@@ -7,18 +7,16 @@
* *
* *
* IDENTIFICATION * IDENTIFICATION
* $Header: /cvsroot/pgsql/src/backend/utils/error/assert.c,v 1.13 1999/02/13 23:19:47 momjian Exp $ * $Header: /cvsroot/pgsql/src/backend/utils/error/assert.c,v 1.13.2.1 1999/08/02 05:25:04 scrappy Exp $
* *
* NOTE * NOTE
* This should eventually work with elog(), dlog(), etc. * This should eventually work with elog(), dlog(), etc.
* *
*------------------------------------------------------------------------- *-------------------------------------------------------------------------
*/ */
#include <stdio.h>
#include <unistd.h> #include <unistd.h>
#include "postgres.h" /* where the declaration goes */ #include "postgres.h"
#include "utils/module.h"
#include "utils/exc.h" #include "utils/exc.h"
#include "utils/trace.h" #include "utils/trace.h"

View File

@@ -7,31 +7,28 @@
* *
* *
* IDENTIFICATION * IDENTIFICATION
* $Header: /cvsroot/pgsql/src/backend/utils/error/elog.c,v 1.45 1999/05/25 16:12:24 momjian Exp $ * $Header: /cvsroot/pgsql/src/backend/utils/error/elog.c,v 1.45.2.1 1999/08/02 05:25:04 scrappy Exp $
* *
*------------------------------------------------------------------------- *-------------------------------------------------------------------------
*/ */
#include <stdio.h>
#include <string.h>
#include <time.h> #include <time.h>
#include <fcntl.h> #include <fcntl.h>
#ifndef O_RDONLY #ifndef O_RDONLY
#include <sys/file.h> #include <sys/file.h>
#endif /* O_RDONLY */ #endif /* O_RDONLY */
#include <sys/types.h> #include <sys/types.h>
#include <stdarg.h>
#include <errno.h> #include <errno.h>
#include <unistd.h> #include <unistd.h>
#include <signal.h> #include <signal.h>
#include "postgres.h"
#ifdef USE_SYSLOG #ifdef USE_SYSLOG
#include <syslog.h> #include <syslog.h>
#endif #endif
#include "postgres.h"
#include "miscadmin.h"
#include "libpq/libpq.h" #include "libpq/libpq.h"
#include "libpq/pqformat.h" #include "libpq/pqformat.h"
#include "miscadmin.h"
#include "storage/proc.h" #include "storage/proc.h"
#include "tcop/tcopprot.h" #include "tcop/tcopprot.h"
#include "utils/trace.h" #include "utils/trace.h"

View File

@@ -7,7 +7,7 @@
* *
* *
* IDENTIFICATION * IDENTIFICATION
* $Header: /cvsroot/pgsql/src/backend/utils/error/Attic/exc.c,v 1.25 1999/05/25 16:12:26 momjian Exp $ * $Header: /cvsroot/pgsql/src/backend/utils/error/Attic/exc.c,v 1.25.2.1 1999/08/02 05:25:04 scrappy Exp $
* *
* NOTE * NOTE
* XXX this code needs improvement--check for state violations and * XXX this code needs improvement--check for state violations and
@@ -15,14 +15,12 @@
* *
*------------------------------------------------------------------------- *-------------------------------------------------------------------------
*/ */
#include <stdio.h> /* XXX use own I/O routines */
#include <errno.h> #include <errno.h>
#include <string.h>
#include "postgres.h" #include "postgres.h"
#include "utils/exc.h"
#include "storage/ipc.h" #include "storage/ipc.h"
#include "utils/exc.h"
static void ExcUnCaught(Exception *excP, ExcDetail detail, ExcData data, static void ExcUnCaught(Exception *excP, ExcDetail detail, ExcData data,
ExcMessage message); ExcMessage message);

View File

@@ -7,14 +7,14 @@
* *
* *
* IDENTIFICATION * IDENTIFICATION
* $Header: /cvsroot/pgsql/src/backend/utils/error/Attic/excabort.c,v 1.6 1999/02/13 23:19:48 momjian Exp $ * $Header: /cvsroot/pgsql/src/backend/utils/error/Attic/excabort.c,v 1.6.2.1 1999/08/02 05:25:04 scrappy Exp $
* *
*------------------------------------------------------------------------- *-------------------------------------------------------------------------
*/ */
#include "postgres.h" #include "postgres.h"
#include "utils/exc.h" /* where function declarations go */ #include "utils/exc.h"
void void
ExcAbort(const Exception *excP, ExcAbort(const Exception *excP,

View File

@@ -7,15 +7,13 @@
* *
* *
* IDENTIFICATION * IDENTIFICATION
* $Header: /cvsroot/pgsql/src/backend/utils/error/Attic/excid.c,v 1.6 1999/05/25 16:12:26 momjian Exp $ * $Header: /cvsroot/pgsql/src/backend/utils/error/Attic/excid.c,v 1.6.2.1 1999/08/02 05:25:04 scrappy Exp $
* *
*------------------------------------------------------------------------- *-------------------------------------------------------------------------
*/ */
#include "postgres.h" #include "postgres.h"
#include "utils/excid.h"
/***************************************************************************** /*****************************************************************************
* Generic Recoverable Exceptions * * Generic Recoverable Exceptions *
*****************************************************************************/ *****************************************************************************/

View File

@@ -7,12 +7,10 @@
* *
* *
* IDENTIFICATION * IDENTIFICATION
* $Header: /cvsroot/pgsql/src/backend/utils/error/Attic/format.c,v 1.13 1999/06/19 05:00:28 momjian Exp $ * $Header: /cvsroot/pgsql/src/backend/utils/error/Attic/format.c,v 1.13.2.1 1999/08/02 05:25:05 scrappy Exp $
* *
*------------------------------------------------------------------------- *-------------------------------------------------------------------------
*/ */
#include <stdio.h>
#include <stdarg.h>
#include "postgres.h" #include "postgres.h"
#define FormMaxSize 1024 #define FormMaxSize 1024

View File

@@ -7,34 +7,23 @@
* *
* *
* IDENTIFICATION * IDENTIFICATION
* $Header: /cvsroot/pgsql/src/backend/utils/fmgr/dfmgr.c,v 1.26 1999/05/25 16:12:27 momjian Exp $ * $Header: /cvsroot/pgsql/src/backend/utils/fmgr/dfmgr.c,v 1.26.2.1 1999/08/02 05:25:06 scrappy Exp $
* *
*------------------------------------------------------------------------- *-------------------------------------------------------------------------
*/ */
#include <sys/types.h> #include <sys/types.h>
#include <sys/stat.h> #include <sys/stat.h>
#include <stdio.h>
#include <string.h>
#include "postgres.h" #include "postgres.h"
#include "config.h" /* for MAXPATHLEN */
#include "fmgr.h" /* generated by Gen_fmgrtab.sh */
#include "utils/dynamic_loader.h" #include "utils/dynamic_loader.h"
#include "utils/elog.h"
#include "utils/builtins.h"
#include "access/heapam.h" #include "access/heapam.h"
#include "nodes/pg_list.h"
#include "dynloader.h"
#ifdef __ultrix
#include <dl.h>
#endif
#include "catalog/catname.h" #include "catalog/catname.h"
#include "utils/syscache.h"
#include "catalog/pg_proc.h" #include "catalog/pg_proc.h"
#include "dynloader.h"
#include "utils/builtins.h"
#include "utils/syscache.h"
static DynamicFileList *file_list = (DynamicFileList *) NULL; static DynamicFileList *file_list = (DynamicFileList *) NULL;
static DynamicFileList *file_tail = (DynamicFileList *) NULL; static DynamicFileList *file_tail = (DynamicFileList *) NULL;

View File

@@ -7,31 +7,19 @@
* *
* *
* IDENTIFICATION * IDENTIFICATION
* $Header: /cvsroot/pgsql/src/backend/utils/fmgr/fmgr.c,v 1.28 1999/05/25 16:12:28 momjian Exp $ * $Header: /cvsroot/pgsql/src/backend/utils/fmgr/fmgr.c,v 1.28.2.1 1999/08/02 05:25:06 scrappy Exp $
* *
*------------------------------------------------------------------------- *-------------------------------------------------------------------------
*/ */
#include <stdio.h>
#include <stdarg.h>
#include <string.h>
#include "postgres.h" #include "postgres.h"
/* these 2 files are generated by Gen_fmgrtab.sh; contain the declarations */
#include "fmgr.h"
#include "utils/fmgrtab.h"
#include "nodes/pg_list.h"
#include "catalog/pg_proc.h"
#include "catalog/pg_language.h" #include "catalog/pg_language.h"
#include "utils/syscache.h" #include "catalog/pg_proc.h"
#include "nodes/params.h"
#include "utils/builtins.h"
#include "utils/elog.h"
#include "nodes/parsenodes.h"
#include "commands/trigger.h" #include "commands/trigger.h"
#include "utils/builtins.h"
#include "utils/fmgrtab.h"
#include "utils/syscache.h"
/* /*

View File

@@ -7,7 +7,7 @@
* *
* *
* IDENTIFICATION * IDENTIFICATION
* $Header: /cvsroot/pgsql/src/backend/utils/hash/dynahash.c,v 1.23 1999/05/31 17:01:52 tgl Exp $ * $Header: /cvsroot/pgsql/src/backend/utils/hash/dynahash.c,v 1.23.2.1 1999/08/02 05:25:08 scrappy Exp $
* *
*------------------------------------------------------------------------- *-------------------------------------------------------------------------
*/ */
@@ -39,17 +39,12 @@
* Modified by sullivan@postgres.berkeley.edu April 1990 * Modified by sullivan@postgres.berkeley.edu April 1990
* changed ctl structure for shared memory * changed ctl structure for shared memory
*/ */
#include <stdio.h> #include <sys/types.h>
#include <sys/types.h>
#include <string.h> #include "postgres.h"
#include "postgres.h" #include "utils/dynahash.h"
#include "utils/dynahash.h" #include "utils/hsearch.h"
#include "utils/hsearch.h" #include "utils/memutils.h"
#ifndef FRONTEND
#include "utils/mcxt.h"
#endif /* !FRONTEND */
#include "utils/palloc.h"
#include "utils/memutils.h"
/* /*
* Fast MOD arithmetic, assuming that y is a power of 2 ! * Fast MOD arithmetic, assuming that y is a power of 2 !

View File

@@ -7,11 +7,10 @@
* *
* *
* IDENTIFICATION * IDENTIFICATION
* $Header: /cvsroot/pgsql/src/backend/utils/hash/hashfn.c,v 1.9 1999/02/13 23:19:56 momjian Exp $ * $Header: /cvsroot/pgsql/src/backend/utils/hash/hashfn.c,v 1.9.2.1 1999/08/02 05:25:08 scrappy Exp $
* *
*------------------------------------------------------------------------- *-------------------------------------------------------------------------
*/ */
#include <string.h>
#include "postgres.h" #include "postgres.h"
#include "utils/hsearch.h" #include "utils/hsearch.h"

View File

@@ -7,12 +7,12 @@
* *
* *
* IDENTIFICATION * IDENTIFICATION
* $Header: /cvsroot/pgsql/src/backend/utils/init/Attic/enbl.c,v 1.7 1999/05/25 16:12:33 momjian Exp $ * $Header: /cvsroot/pgsql/src/backend/utils/init/Attic/enbl.c,v 1.7.2.1 1999/08/02 05:25:09 scrappy Exp $
* *
*------------------------------------------------------------------------- *-------------------------------------------------------------------------
*/ */
#include "postgres.h" #include "postgres.h"
#include "utils/module.h" /* where the declarations go */ #include "utils/module.h"
/* /*
* BypassEnable * BypassEnable

View File

@@ -6,20 +6,18 @@
* *
* *
* IDENTIFICATION * IDENTIFICATION
* $Header: /cvsroot/pgsql/src/backend/utils/init/Attic/findbe.c,v 1.14 1999/05/25 16:12:33 momjian Exp $ * $Header: /cvsroot/pgsql/src/backend/utils/init/Attic/findbe.c,v 1.14.2.1 1999/08/02 05:25:09 scrappy Exp $
* *
*------------------------------------------------------------------------- *-------------------------------------------------------------------------
*/ */
#include <stdio.h>
#include <grp.h> #include <grp.h>
#include <pwd.h> #include <pwd.h>
#include <string.h>
#include <sys/types.h> #include <sys/types.h>
#include <sys/stat.h> #include <sys/stat.h>
#include <unistd.h> #include <unistd.h>
#include "postgres.h" #include "postgres.h"
#include "miscadmin.h" /* for DebugLvl */ #include "miscadmin.h"
#ifndef S_IRUSR /* XXX [TRH] should be in a header */ #ifndef S_IRUSR /* XXX [TRH] should be in a header */
#define S_IRUSR S_IREAD #define S_IRUSR S_IREAD

View File

@@ -7,7 +7,7 @@
* *
* *
* IDENTIFICATION * IDENTIFICATION
* $Header: /cvsroot/pgsql/src/backend/utils/init/globals.c,v 1.30 1999/05/25 16:12:34 momjian Exp $ * $Header: /cvsroot/pgsql/src/backend/utils/init/globals.c,v 1.30.2.1 1999/08/02 05:25:10 scrappy Exp $
* *
* NOTES * NOTES
* Globals used all over the place should be declared here and not * Globals used all over the place should be declared here and not
@@ -16,24 +16,18 @@
*------------------------------------------------------------------------- *-------------------------------------------------------------------------
*/ */
#include <fcntl.h> #include <fcntl.h>
#include <stdio.h>
#include <string.h>
#include <sys/file.h> #include <sys/file.h>
#include <sys/types.h> #include <sys/types.h>
#include <math.h> #include <math.h>
#include <unistd.h> #include <unistd.h>
#include "postgres.h" #include "postgres.h"
#include "miscadmin.h" /* where the declarations go */
#include <storage/backendid.h>
#include "access/heapam.h"
#include "storage/sinval.h"
#include "storage/sinvaladt.h"
#include "storage/lmgr.h"
#include "utils/elog.h"
#include "libpq/pqcomm.h"
#include "catalog/catname.h" #include "catalog/catname.h"
#include "libpq/pqcomm.h"
#include "miscadmin.h"
#include "storage/backendid.h"
#include "storage/lmgr.h"
ProtocolVersion FrontendProtocol = PG_PROTOCOL_LATEST; ProtocolVersion FrontendProtocol = PG_PROTOCOL_LATEST;

View File

@@ -7,37 +7,24 @@
* *
* *
* IDENTIFICATION * IDENTIFICATION
* $Header: /cvsroot/pgsql/src/backend/utils/init/miscinit.c,v 1.29 1999/05/25 16:12:35 momjian Exp $ * $Header: /cvsroot/pgsql/src/backend/utils/init/miscinit.c,v 1.29.2.1 1999/08/02 05:25:10 scrappy Exp $
* *
*------------------------------------------------------------------------- *-------------------------------------------------------------------------
*/ */
#include <string.h> #include <sys/param.h>
#include <sys/param.h> /* for MAXPATHLEN */
#include <sys/types.h> #include <sys/types.h>
#include <sys/stat.h> #include <sys/stat.h>
#include <sys/file.h> #include <sys/file.h>
#include <stdio.h>
#include <unistd.h> #include <unistd.h>
#include <grp.h> /* for getgrgid */ #include <grp.h>
#include <pwd.h> /* for getpwuid */ #include <pwd.h>
#include "postgres.h" #include "postgres.h"
#include "utils/portal.h" /* for EnablePortalManager, etc. */
#include "utils/exc.h" /* for EnableExceptionHandling, etc. */
#include "utils/mcxt.h" /* for EnableMemoryContext, etc. */
#include "utils/elog.h"
#include "utils/builtins.h"
#include "miscadmin.h" /* where the declarations go */
#include "catalog/catname.h" #include "catalog/catname.h"
#include "catalog/pg_shadow.h" #include "catalog/pg_shadow.h"
#include "catalog/pg_proc.h" #include "miscadmin.h"
#include "utils/syscache.h" #include "utils/syscache.h"
#include "storage/fd.h" /* for O_ */
#include "storage/ipc.h" /* for proc_exit */
/* /*
* EnableAbortEnvVarName * EnableAbortEnvVarName

View File

@@ -7,7 +7,7 @@
* *
* *
* IDENTIFICATION * IDENTIFICATION
* $Header: /cvsroot/pgsql/src/backend/utils/init/postinit.c,v 1.40 1999/05/25 16:12:36 momjian Exp $ * $Header: /cvsroot/pgsql/src/backend/utils/init/postinit.c,v 1.40.2.1 1999/08/02 05:25:10 scrappy Exp $
* *
* NOTES * NOTES
* InitPostgres() is the function called from PostgresMain * InitPostgres() is the function called from PostgresMain
@@ -27,51 +27,31 @@
*------------------------------------------------------------------------- *-------------------------------------------------------------------------
*/ */
#include <fcntl.h> #include <fcntl.h>
#include <stdio.h>
#include <string.h>
#include <sys/file.h> #include <sys/file.h>
#include <sys/types.h> #include <sys/types.h>
#include <math.h> #include <math.h>
#include <unistd.h> #include <unistd.h>
#include "postgres.h" #include "postgres.h"
#include "version.h"
#include <storage/ipc.h>
#include <storage/backendid.h>
#include <storage/buf_internals.h>
#include <storage/smgr.h>
#include <storage/proc.h>
#include <utils/relcache.h>
#include "access/heapam.h" #include "access/heapam.h"
#include "access/xact.h"
#include "storage/bufmgr.h"
#include "access/transam.h" /* XXX dependency problem */
#include "utils/syscache.h"
#include "storage/bufpage.h" /* for page layout, for
* InitMyDatabaseInfo() */
#include "storage/sinval.h"
#include "storage/sinvaladt.h"
#include "storage/lmgr.h"
#include "miscadmin.h" /* for global decls */
#include "utils/portal.h" /* for EnablePortalManager, etc. */
#include "utils/exc.h" /* for EnableExceptionHandling, etc. */
#include "fmgr.h" /* for EnableDynamicFunctionManager, etc. */
#include "utils/elog.h"
#include "utils/palloc.h"
#include "utils/mcxt.h" /* for EnableMemoryContext, etc. */
#include "utils/inval.h"
#include "catalog/catname.h" #include "catalog/catname.h"
#include "libpq/libpq.h"
#include "miscadmin.h"
#include "storage/backendid.h"
#include "storage/proc.h"
#include "storage/sinval.h"
#include "storage/smgr.h"
#include "utils/inval.h"
#include "utils/portal.h"
#include "utils/relcache.h"
#include "utils/syscache.h"
#include "version.h"
#ifdef MULTIBYTE #ifdef MULTIBYTE
#include "mb/pg_wchar.h" #include "mb/pg_wchar.h"
#endif #endif
#include "libpq/libpq.h"
static void VerifySystemDatabase(void); static void VerifySystemDatabase(void);
static void VerifyMyDatabase(void); static void VerifyMyDatabase(void);
static void InitCommunication(void); static void InitCommunication(void);

Some files were not shown because too many files have changed in this diff Show More