OSDN Git Service

Compile and warning cleanup
authorBruce Momjian <bruce@momjian.us>
Fri, 8 Nov 1996 06:02:30 +0000 (06:02 +0000)
committerBruce Momjian <bruce@momjian.us>
Fri, 8 Nov 1996 06:02:30 +0000 (06:02 +0000)
85 files changed:
src/backend/bootstrap/Makefile
src/backend/commands/define.c
src/backend/executor/execJunk.c
src/backend/executor/execTuples.c
src/backend/executor/nodeGroup.c
src/backend/executor/nodeNestloop.c
src/backend/executor/nodeSeqscan.c
src/backend/executor/nodeSort.c
src/backend/executor/nodeUnique.c
src/backend/libpq/pqcomm.c
src/backend/main/main.c
src/backend/nodes/copyfuncs.c
src/backend/nodes/equalfuncs.c
src/backend/nodes/outfuncs.c
src/backend/nodes/read.c
src/backend/nodes/readfuncs.c
src/backend/optimizer/path/allpaths.c
src/backend/optimizer/path/indxpath.c
src/backend/optimizer/path/prune.c
src/backend/optimizer/plan/createplan.c
src/backend/parser/Makefile
src/backend/parser/analyze.c
src/backend/parser/catalog_utils.c
src/backend/parser/dbcommands.c
src/backend/parser/parser.c
src/backend/parser/sysfunc.c
src/backend/port/bsdi/port-protos.h
src/backend/postmaster/postmaster.c
src/backend/regex/regcomp.c
src/backend/regex/regerror.c
src/backend/regex/regexec.c
src/backend/rewrite/rewriteSupport.c
src/backend/storage/buffer/buf_init.c
src/backend/storage/buffer/bufmgr.c
src/backend/storage/buffer/localbuf.c
src/backend/storage/file/fd.c
src/backend/storage/ipc/ipc.c
src/backend/storage/ipc/ipci.c
src/backend/storage/ipc/shmem.c
src/backend/storage/large_object/inv_api.c
src/backend/storage/lmgr/lmgr.c
src/backend/storage/lmgr/lock.c
src/backend/storage/lmgr/proc.c
src/backend/storage/page/bufpage.c
src/backend/storage/smgr/md.c
src/backend/storage/smgr/mm.c
src/backend/storage/smgr/smgr.c
src/backend/tcop/Makefile
src/backend/tcop/aclchk.c
src/backend/tcop/fastpath.c
src/backend/tcop/postgres.c
src/backend/tcop/pquery.c
src/backend/tcop/utility.c
src/backend/utils/adt/arrayfuncs.c
src/backend/utils/adt/chunk.c
src/backend/utils/adt/datum.c
src/backend/utils/adt/filename.c
src/backend/utils/adt/nabstime.c
src/backend/utils/adt/regproc.c
src/backend/utils/adt/sets.c
src/backend/utils/adt/varlena.c
src/backend/utils/cache/catcache.c
src/backend/utils/cache/inval.c
src/backend/utils/error/elog.c
src/backend/utils/fmgr/fmgr.c
src/backend/utils/hash/dynahash.c
src/backend/utils/init/postinit.c
src/backend/utils/mmgr/aset.c
src/backend/utils/mmgr/mcxt.c
src/backend/utils/mmgr/portalmem.c
src/bin/pg_dump/pg_dump.c
src/bin/pg_id/pg_id.c
src/bin/pg_version/pg_version.c
src/bin/psql/Makefile
src/bin/psql/psql.c
src/include/bootstrap/bootstrap.h
src/include/commands/async.h
src/include/config.h
src/include/rewrite/locks.h
src/include/storage/fd.h
src/include/storage/lmgr.h
src/include/storage/smgr.h
src/interfaces/libpq/Makefile
src/interfaces/libpq/fe-lobj.c
src/interfaces/libpq/pqsignal.c

index 66ed86f..b5dd5c5 100644 (file)
@@ -4,7 +4,7 @@
 #    Makefile for the bootstrap module
 #
 # IDENTIFICATION
-#    $Header: /cvsroot/pgsql/src/backend/bootstrap/Makefile,v 1.1 1996/10/27 09:46:59 bryanh Exp $
+#    $Header: /cvsroot/pgsql/src/backend/bootstrap/Makefile,v 1.2 1996/11/08 05:55:46 momjian Exp $
 #
 #
 # We must build bootparse.c and bootscanner.c with yacc and lex and sed,
@@ -26,7 +26,7 @@ INCLUDE_OPT = -I.. \
               -I../include \
               -I../../include
 
-CFLAGS += $(INCLUDE_OPT)
+CFLAGS += $(INCLUDE_OPT) -Wno-error
 
 BOOTYACCS = bootstrap_tokens.h bootparse.c
 
index 89ac127..fe696b8 100644 (file)
@@ -9,7 +9,7 @@
  *
  *
  * IDENTIFICATION
- *    $Header: /cvsroot/pgsql/src/backend/commands/define.c,v 1.6 1996/11/06 08:21:34 scrappy Exp $
+ *    $Header: /cvsroot/pgsql/src/backend/commands/define.c,v 1.7 1996/11/08 05:55:49 momjian Exp $
  *
  * DESCRIPTION
  *    The "DefineFoo" routines take the parse tree and pick out the
@@ -136,8 +136,9 @@ compute_full_attributes(const List *parameters, int32 *byte_pct_p,
             */
             *byte_pct_p = atoi(param->val);
         } else if (strcasecmp(param->name, "perbyte_cpu") == 0) {
+                       count = 0;
             if (sscanf(param->val, "%d", perbyte_cpu_p) == 0) {
-                for (count = 0, ptr = param->val; *ptr != '\0'; ptr++) 
+                for (ptr = param->val; *ptr != '\0'; ptr++) 
                     if (*ptr == '!') count++;
             }
             *perbyte_cpu_p = (int) pow(10.0, (double) count);
index dc1fc13..79e0e02 100644 (file)
@@ -7,7 +7,7 @@
  *
  *
  * IDENTIFICATION
- *    $Header: /cvsroot/pgsql/src/backend/executor/execJunk.c,v 1.2 1996/10/31 10:11:23 scrappy Exp $
+ *    $Header: /cvsroot/pgsql/src/backend/executor/execJunk.c,v 1.3 1996/11/08 05:55:55 momjian Exp $
  *
  *-------------------------------------------------------------------------
  */
@@ -15,6 +15,8 @@
 #include "postgres.h"
 
 #include "utils/palloc.h"
+#include "access/heaptuple.h"
+#include "access/heapam.h"
 #include "executor/executor.h"
 #include "nodes/relation.h"
 #include "optimizer/tlist.h" /* for MakeTLE */
index 32188ce..d60c7c4 100644 (file)
@@ -14,7 +14,7 @@
  *
  *
  * IDENTIFICATION
- *    $Header: /cvsroot/pgsql/src/backend/executor/execTuples.c,v 1.2 1996/10/31 10:11:38 scrappy Exp $
+ *    $Header: /cvsroot/pgsql/src/backend/executor/execTuples.c,v 1.3 1996/11/08 05:56:01 momjian Exp $
  *
  *-------------------------------------------------------------------------
  */
  *     and the TupleTableSlot node in execnodes.h.
  *
  */
+#include <string.h>
+
 #include "postgres.h"
 
 
index c6589e3..7457794 100644 (file)
@@ -13,7 +13,7 @@
  *    columns. (ie. tuples from the same group are consecutive)
  *
  * IDENTIFICATION
- *    $Header: /cvsroot/pgsql/src/backend/executor/nodeGroup.c,v 1.2 1996/10/31 10:11:59 scrappy Exp $
+ *    $Header: /cvsroot/pgsql/src/backend/executor/nodeGroup.c,v 1.3 1996/11/08 05:56:08 momjian Exp $
  *
  *-------------------------------------------------------------------------
  */
@@ -21,6 +21,7 @@
 
 #include "access/heapam.h"
 #include "catalog/catalog.h"
+#include "access/printtup.h"
 #include "executor/executor.h"
 #include "executor/nodeGroup.h"
 
index e7efabb..d83d306 100644 (file)
@@ -7,7 +7,7 @@
  *
  *
  * IDENTIFICATION
- *    $Header: /cvsroot/pgsql/src/backend/executor/nodeNestloop.c,v 1.2 1996/10/31 10:12:14 scrappy Exp $
+ *    $Header: /cvsroot/pgsql/src/backend/executor/nodeNestloop.c,v 1.3 1996/11/08 05:56:15 momjian Exp $
  *
  *-------------------------------------------------------------------------
  */
@@ -20,6 +20,7 @@
 #include "postgres.h"
 
 #include "executor/executor.h"
+#include "executor/execdebug.h"
 #include "executor/nodeNestloop.h"
 #include "executor/nodeIndexscan.h"
 
index 1a1c19a..68cb634 100644 (file)
@@ -7,7 +7,7 @@
  *
  *
  * IDENTIFICATION
- *    $Header: /cvsroot/pgsql/src/backend/executor/nodeSeqscan.c,v 1.2 1996/10/31 10:12:20 scrappy Exp $
+ *    $Header: /cvsroot/pgsql/src/backend/executor/nodeSeqscan.c,v 1.3 1996/11/08 05:56:16 momjian Exp $
  *
  *-------------------------------------------------------------------------
  */
@@ -25,7 +25,9 @@
 #include "postgres.h"
 
 #include "executor/executor.h"
+#include "executor/execdebug.h"
 #include "executor/nodeSeqscan.h"
+#include "access/heapam.h"
 #include "parser/parsetree.h"
 
 /* ----------------------------------------------------------------
index b6b66ce..83d7807 100644 (file)
@@ -7,17 +7,20 @@
  *
  *
  * IDENTIFICATION
- *    $Header: /cvsroot/pgsql/src/backend/executor/nodeSort.c,v 1.3 1996/10/31 10:12:22 scrappy Exp $
+ *    $Header: /cvsroot/pgsql/src/backend/executor/nodeSort.c,v 1.4 1996/11/08 05:56:17 momjian Exp $
  *
  *-------------------------------------------------------------------------
  */
 #include "postgres.h"
 
 #include "executor/executor.h"
+#include "executor/execdebug.h"
 #include "executor/nodeSort.h"
+#include "access/heapam.h"
 #include "utils/palloc.h"
 #include "utils/psort.h"
 #include "catalog/catalog.h"
+#include "catalog/heap.h"
 #include "storage/bufmgr.h"
 #include "optimizer/internal.h" /* for _TEMP_RELATION_ID_ */
 
index 1a68f86..18e25a4 100644 (file)
@@ -7,7 +7,7 @@
  *
  *
  * IDENTIFICATION
- *    $Header: /cvsroot/pgsql/src/backend/executor/nodeUnique.c,v 1.3 1996/10/31 10:12:26 scrappy Exp $
+ *    $Header: /cvsroot/pgsql/src/backend/executor/nodeUnique.c,v 1.4 1996/11/08 05:56:19 momjian Exp $
  *
  *-------------------------------------------------------------------------
  */
@@ -27,6 +27,8 @@
 #include "executor/executor.h"
 #include "executor/nodeUnique.h"
 #include "optimizer/clauses.h"
+#include "access/heapam.h"
+#include "access/heaptuple.h"
 #include "access/printtup.h" /* for typtoout() */
 #include "utils/builtins.h"  /* for namecpy()*/
 
@@ -128,6 +130,10 @@ ExecUnique(Unique *node)
       tupDesc = ExecGetResultType(uniquestate);
       typoutput = typtoout((Oid)tupDesc->attrs[uniqueAttrNum-1]->atttypid);
     }
+    else { /* keep compiler quiet */
+      tupDesc = NULL;
+      typoutput = 0;
+    }
       
     /* ----------------
      * now loop, returning only non-duplicate tuples.
index ada4d4a..7670751 100644 (file)
@@ -7,7 +7,7 @@
  *
  *
  * IDENTIFICATION
- *    $Header: /cvsroot/pgsql/src/backend/libpq/pqcomm.c,v 1.5 1996/11/06 08:48:30 scrappy Exp $
+ *    $Header: /cvsroot/pgsql/src/backend/libpq/pqcomm.c,v 1.6 1996/11/08 05:56:21 momjian Exp $
  *
  *-------------------------------------------------------------------------
  */
@@ -181,7 +181,7 @@ pq_flush()
 int
 pq_getstr(char *s, int maxlen)
 {
-    int        c;
+    int        c = '\0';
     
     if (Pfin == (FILE *) NULL) {
 /*     elog(DEBUG, "Input descriptor is null"); */
@@ -266,7 +266,7 @@ PQputline(char *s)
 int
 pq_getnchar(char *s, int off, int maxlen)
 {
-    int        c;
+    int        c = '\0';
     
     if (Pfin == (FILE *) NULL) {
 /*     elog(DEBUG, "Input descriptor is null"); */
index 0c8dbc4..4d2710b 100644 (file)
@@ -7,12 +7,12 @@
  *
  *
  * IDENTIFICATION
- *    $Header: /cvsroot/pgsql/src/backend/main/main.c,v 1.1.1.1 1996/07/09 06:21:32 scrappy Exp $
+ *    $Header: /cvsroot/pgsql/src/backend/main/main.c,v 1.2 1996/11/08 05:56:27 momjian Exp $
  *
  *-------------------------------------------------------------------------
  */
 #include <string.h>
-#include "c.h"
+#include "postgres.h"
 #include "miscadmin.h"
 #include "bootstrap/bootstrap.h"       /* for BootstrapMain() */
 #include "tcop/tcopprot.h"             /* for PostgresMain() */
index 4f49138..e61a13e 100644 (file)
@@ -7,7 +7,7 @@
  *
  *
  * IDENTIFICATION
- *    $Header: /cvsroot/pgsql/src/backend/nodes/copyfuncs.c,v 1.2 1996/08/19 13:32:14 scrappy Exp $
+ *    $Header: /cvsroot/pgsql/src/backend/nodes/copyfuncs.c,v 1.3 1996/11/08 05:56:35 momjian Exp $
  *
  *-------------------------------------------------------------------------
  */
@@ -39,7 +39,7 @@ List *
 listCopy(List *list)
 {
     List *newlist=NIL;
-    List *l, *nl;
+    List *l, *nl=NIL;
 
     foreach(l, list) {
        if (newlist==NIL) {
@@ -1653,7 +1653,7 @@ copyObject(void *from)
     case T_List:
        {
            List *list=from, *l;
-           List *newlist = NIL, *nl;
+           List *newlist = NIL, *nl=NIL;
            foreach(l, list) {
                if (newlist==NIL) {
                    newlist = nl = lcons(copyObject(lfirst(l)),NIL);
index 54cafe4..57226d5 100644 (file)
@@ -7,7 +7,7 @@
  *
  *
  * IDENTIFICATION
- *    $Header: /cvsroot/pgsql/src/backend/nodes/equalfuncs.c,v 1.2 1996/08/26 06:30:51 scrappy Exp $
+ *    $Header: /cvsroot/pgsql/src/backend/nodes/equalfuncs.c,v 1.3 1996/11/08 05:56:39 momjian Exp $
  *
  *-------------------------------------------------------------------------
  */
@@ -570,7 +570,7 @@ _equalValue(Value *a, Value *b)
 bool
 equal(void *a, void *b)
 {
-    bool retval;
+    bool retval=false;
     
     if (a == b)
        return(true);
index 5281d52..aa9f3fd 100644 (file)
@@ -7,7 +7,7 @@
  *
  *
  * IDENTIFICATION
- *    $Header: /cvsroot/pgsql/src/backend/nodes/outfuncs.c,v 1.1.1.1 1996/07/09 06:21:33 scrappy Exp $
+ *    $Header: /cvsroot/pgsql/src/backend/nodes/outfuncs.c,v 1.2 1996/11/08 05:56:43 momjian Exp $
  *
  * NOTES
  *    Every (plan) node in POSTGRES has an associated "out" routine which
@@ -548,7 +548,7 @@ static void
 _outExpr(StringInfo str, Expr *node)
 {
     char buf[500];
-    char *opstr;
+    char *opstr = NULL;
     
     sprintf(buf, "EXPR");
     appendStringInfo(str,buf);
index dbcc59a..d2fa81c 100644 (file)
@@ -8,7 +8,7 @@
  *
  *
  * IDENTIFICATION
- *    $Header: /cvsroot/pgsql/src/backend/nodes/read.c,v 1.1.1.1 1996/07/09 06:21:33 scrappy Exp $
+ *    $Header: /cvsroot/pgsql/src/backend/nodes/read.c,v 1.2 1996/11/08 05:56:48 momjian Exp $
  *
  * HISTORY
  *    AUTHOR           DATE            MAJOR EVENT
@@ -64,7 +64,7 @@ stringToNode(char *str)
 static NodeTag
 nodeTokenType(char *token, int length)
 {
-    NodeTag retval;
+    NodeTag retval = 0;
     
     /*
      * Check if the token is a number (decimal or integer,
@@ -168,7 +168,7 @@ nodeRead(bool read_car_only)
 {
     char *token;
     NodeTag type;
-    Node *this_value, *return_value;
+    Node *this_value = NULL, *return_value = NULL;
     int tok_len;
     char tmp;
     bool make_dotted_pair_cell = false;
index f0d9e3b..692e14a 100644 (file)
@@ -7,7 +7,7 @@
  *
  *
  * IDENTIFICATION
- *    $Header: /cvsroot/pgsql/src/backend/nodes/readfuncs.c,v 1.2 1996/07/31 02:18:48 scrappy Exp $
+ *    $Header: /cvsroot/pgsql/src/backend/nodes/readfuncs.c,v 1.3 1996/11/08 05:56:49 momjian Exp $
  *
  * NOTES
  *    Most of the read functions for plan nodes are tested. (In fact, they
@@ -1047,7 +1047,7 @@ _readEState()
     token = lsptok(NULL, &length);      /* get @ */
     token = lsptok(NULL, &length);      /* now read it */
     
-    sscanf(token, "%x", &local_node->es_result_relation_info);
+    sscanf(token, "%x",(unsigned int *)&local_node->es_result_relation_info);
     
     return(local_node);
 }
@@ -1117,13 +1117,13 @@ _readRel()
     token = lsptok(NULL, &length);      /* get @ */
     token = lsptok(NULL, &length);      /* now read it */
     
-    sscanf(token, "%x", &local_node->unorderedpath);
+    sscanf(token, "%x", (unsigned int *)&local_node->unorderedpath);
     
     token = lsptok(NULL, &length);      /* get :cheapestpath */
     token = lsptok(NULL, &length);      /* get @ */
     token = lsptok(NULL, &length);      /* now read it */
     
-    sscanf(token, "%x", &local_node->cheapestpath);
+    sscanf(token, "%x", (unsigned int *)&local_node->cheapestpath);
     
     
     token = lsptok(NULL, &length);      /* get :clauseinfo */
@@ -1792,7 +1792,7 @@ parsePlanString()
 {
     char *token;
     int length;
-    void *return_value;
+    void *return_value = NULL;
     
     token = lsptok(NULL, &length);
     
index d984765..9b0bca2 100644 (file)
@@ -7,7 +7,7 @@
  *
  *
  * IDENTIFICATION
- *    $Header: /cvsroot/pgsql/src/backend/optimizer/path/allpaths.c,v 1.2 1996/11/06 09:29:03 scrappy Exp $
+ *    $Header: /cvsroot/pgsql/src/backend/optimizer/path/allpaths.c,v 1.3 1996/11/08 05:56:52 momjian Exp $
  *
  *-------------------------------------------------------------------------
  */
@@ -255,7 +255,7 @@ print_path(Query *root, Path *path, int indent)
 {
     char *ptype = NULL;
     JoinPath *jp;
-    bool join;
+    bool join = false;
     int i;
 
     for(i=0; i < indent; i++)
index 57d26dc..41cbdf9 100644 (file)
@@ -8,7 +8,7 @@
  *
  *
  * IDENTIFICATION
- *    $Header: /cvsroot/pgsql/src/backend/optimizer/path/indxpath.c,v 1.3 1996/09/10 06:48:12 scrappy Exp $
+ *    $Header: /cvsroot/pgsql/src/backend/optimizer/path/indxpath.c,v 1.4 1996/11/08 05:56:55 momjian Exp $
  *
  *-------------------------------------------------------------------------
  */
@@ -981,6 +981,7 @@ indexable_joinclauses(Rel *rel, Rel *index, List *joininfo_list)
  *    the list of clause info contains join clauses and restriction clauses.
  *    This routine returns the restriction clauses only.
  */
+#ifdef NOT_USED
 static List *
 extract_restrict_clauses(List *clausegroup)
 {
@@ -996,6 +997,7 @@ extract_restrict_clauses(List *clausegroup)
     }
     return restrict_cls;
 }
+#endif
 
 /*    
  * index-innerjoin--
index 70f9b20..6f8a28c 100644 (file)
@@ -7,7 +7,7 @@
  *
  *
  * IDENTIFICATION
- *    $Header: /cvsroot/pgsql/src/backend/optimizer/path/Attic/prune.c,v 1.1.1.1 1996/07/09 06:21:36 scrappy Exp $
+ *    $Header: /cvsroot/pgsql/src/backend/optimizer/path/Attic/prune.c,v 1.2 1996/11/08 05:57:01 momjian Exp $
  *
  *-------------------------------------------------------------------------
  */
@@ -95,7 +95,7 @@ prune_rel_paths(List *rel_list)
 {
     List *x = NIL;
     List *y = NIL;
-    Path *path;
+    Path *path = NULL;
     Rel *rel = (Rel*)NULL;
     JoinPath *cheapest = (JoinPath*)NULL;
     
index 762cdf9..2c576a9 100644 (file)
@@ -7,7 +7,7 @@
  *
  *
  * IDENTIFICATION
- *    $Header: /cvsroot/pgsql/src/backend/optimizer/plan/createplan.c,v 1.5 1996/11/06 09:29:10 scrappy Exp $
+ *    $Header: /cvsroot/pgsql/src/backend/optimizer/plan/createplan.c,v 1.6 1996/11/08 05:57:08 momjian Exp $
  *
  *-------------------------------------------------------------------------
  */
@@ -156,7 +156,7 @@ static Scan *
 create_scan_node(Path *best_path, List *tlist)
 {
 
-    Scan *node;
+    Scan *node = NULL ;
     List *scan_clauses;
 
     /*
@@ -208,7 +208,7 @@ create_join_node(JoinPath *best_path, List *tlist)
     Plan       *inner_node;
     List       *inner_tlist;
     List       *clauses;
-    Join       *retval;
+    Join       *retval = NULL;
 
     outer_node = create_plan((Path*)best_path->outerjoinpath);
     outer_tlist  = outer_node->targetlist;
@@ -803,7 +803,7 @@ make_temp(List *tlist,
          int temptype)
 {
     List *temp_tlist;
-    Temp *retval;
+    Temp *retval = NULL;
 
     /*    Create a new target list for the temporary, with keys set. */
     temp_tlist = set_temp_tlist_operators(new_unsorted_tlist(tlist),
index 69705bb..452c119 100644 (file)
@@ -4,7 +4,7 @@
 #    Makefile for parser
 #
 # IDENTIFICATION
-#    $Header: /cvsroot/pgsql/src/backend/parser/Makefile,v 1.1 1996/10/27 09:49:05 bryanh Exp $
+#    $Header: /cvsroot/pgsql/src/backend/parser/Makefile,v 1.2 1996/11/08 05:57:18 momjian Exp $
 #
 #-------------------------------------------------------------------------
 
@@ -16,7 +16,7 @@ INCLUDE_OPT = -I.. \
               -I../include \
               -I../../include
 
-CFLAGS+=$(INCLUDE_OPT)
+CFLAGS+=$(INCLUDE_OPT) -Wno-error
 
 OBJS = analyze.o catalog_utils.o dbcommands.o gram.o \
        keywords.o parser.o parse_query.o scan.o scansup.o sysfunc.o
index 95b1a81..ead5d0a 100644 (file)
@@ -7,7 +7,7 @@
  *
  *
  * IDENTIFICATION
- *    $Header: /cvsroot/pgsql/src/backend/parser/analyze.c,v 1.12 1996/11/06 06:48:20 scrappy Exp $
+ *    $Header: /cvsroot/pgsql/src/backend/parser/analyze.c,v 1.13 1996/11/08 05:57:25 momjian Exp $
  *
  *-------------------------------------------------------------------------
  */
@@ -274,7 +274,6 @@ static Query *
 transformInsertStmt(ParseState *pstate, AppendStmt *stmt)
 {
     Query *qry = makeNode(Query);      /* make a new query tree */
-    List *targetlist;
 
     qry->commandType = CMD_INSERT;
     pstate->p_is_insert = true;
@@ -531,7 +530,7 @@ transformCursorStmt(ParseState *pstate, CursorStmt *stmt)
 static Node *
 transformExpr(ParseState *pstate, Node *expr)
 {
-    Node *result;
+    Node *result = NULL;
 
     if (expr==NULL)
        return NULL;
@@ -809,7 +808,7 @@ makeRangeTable(ParseState *pstate, char *relname, List *frmList)
 Oid
 exprType(Node *expr)
 {
-    Oid type;
+    Oid type = (Oid)0;
     
     switch(nodeTag(expr)) {
     case T_Func:
@@ -1426,7 +1425,7 @@ static Resdom *
 find_tl_elt(ParseState *pstate, char *refname, char *colname, List *tlist)
 {
     List *i;
-    int real_rtable_pos;
+    int real_rtable_pos = 0;
 
     if(refname)
        real_rtable_pos = refnameRangeTablePosn(pstate->p_rtable, refname);
@@ -1471,7 +1470,7 @@ any_ordering_op(int restype)
 static List *
 transformGroupClause(ParseState *pstate, List *grouplist)
 {
-    List *glist = NIL, *gl;
+    List *glist = NIL, *gl = NIL;
 
     while (grouplist != NIL) {
        GroupClause *grpcl = makeNode(GroupClause);
@@ -1505,7 +1504,7 @@ transformSortClause(ParseState *pstate,
                    char* uniqueFlag)
 {
     List *sortlist = NIL;
-    List *s, *i;
+    List *s = NIL, *i;
 
     while(orderlist != NIL) {
        SortBy *sortby = lfirst(orderlist);
@@ -1555,7 +1554,7 @@ transformSortClause(ParseState *pstate,
          }
       }
       else {
-       TargetEntry *tlelt;
+       TargetEntry *tlelt = NULL;
        char* uniqueAttrName = uniqueFlag;
 
          /* only create sort clause with the specified unique attribute */
@@ -1873,12 +1872,12 @@ static Node *
 ParseFunc(ParseState *pstate, char *funcname, List *fargs, int *curr_resno)
 {
     Oid rettype = (Oid)0;
-    Oid argrelid;
+    Oid argrelid = (Oid)0;
     Oid funcid = (Oid)0;
     List *i = NIL;
     Node *first_arg= NULL;
-    char *relname;
-    char *refname;
+    char *relname = NULL;
+    char *refname = NULL;
     Relation rd;
     Oid relid;
     int nargs;
@@ -1889,7 +1888,7 @@ ParseFunc(ParseState *pstate, char *funcname, List *fargs, int *curr_resno)
     bool retset;
     bool exists;
     bool attisset = false;
-    Oid toid;
+    Oid toid = (Oid)0;
     Expr *expr;
 
     if (fargs) {
index d26cf1c..00745e3 100644 (file)
@@ -6,7 +6,7 @@
  *
  *
  * IDENTIFICATION
- *    $Header: /cvsroot/pgsql/src/backend/parser/Attic/catalog_utils.c,v 1.7 1996/11/06 06:48:23 scrappy Exp $
+ *    $Header: /cvsroot/pgsql/src/backend/parser/Attic/catalog_utils.c,v 1.8 1996/11/08 05:57:29 momjian Exp $
  *
  *-------------------------------------------------------------------------
  */
@@ -1423,7 +1423,7 @@ FindDelimiter(char *typename)
 void
 op_error(char *op, int arg1, int arg2)
 {
-    Type tp1, tp2;
+    Type tp1 = NULL, tp2 = NULL;
 
     if (check_typeid(arg1)) {
        tp1 = get_id_type(arg1);
index 07543fb..029491c 100644 (file)
@@ -7,7 +7,7 @@
  *
  *
  * IDENTIFICATION
- *    $Header: /cvsroot/pgsql/src/backend/parser/Attic/dbcommands.c,v 1.1.1.1 1996/07/09 06:21:40 scrappy Exp $
+ *    $Header: /cvsroot/pgsql/src/backend/parser/Attic/dbcommands.c,v 1.2 1996/11/08 05:57:31 momjian Exp $
  *
  *-------------------------------------------------------------------------
  */
@@ -153,7 +153,7 @@ check_permissions(char *command,
 {
     Relation dbrel;
     HeapTuple dbtup, utup;
-    Oid dbowner;
+    Oid dbowner = (Oid)0;
     char use_createdb;
     bool dbfound;
     bool use_super;
index 344fe3b..3d1a554 100644 (file)
@@ -6,7 +6,7 @@
  *
  *
  * IDENTIFICATION
- *    $Header: /cvsroot/pgsql/src/backend/parser/parser.c,v 1.5 1996/11/06 06:48:26 scrappy Exp $
+ *    $Header: /cvsroot/pgsql/src/backend/parser/parser.c,v 1.6 1996/11/08 05:57:33 momjian Exp $
  *
  *-------------------------------------------------------------------------
  */
 #include "nodes/makefuncs.h"
 #include "optimizer/clauses.h" 
 
+void init_io(); /* from scan.l */
+void parser_init(Oid *typev, int nargs); /* from gram.y */
+int yyparse(); /* from gram.c */
+
 char *parseString; /* the char* which holds the string to be parsed */
 char *parseCh;     /* a pointer used during parsing to walk down ParseString*/
 
 List *parsetree = NIL;
 
+#ifdef SETS_FIXED
 static void fixupsets();
+#endif
 static void define_sets();
 /*
  * parser-- returns a list of parse trees
@@ -99,6 +105,7 @@ parser(char *str, Oid *typev, int nargs)
     return queryList;
 }
 
+#ifdef SETS_FIXED
 static void
 fixupsets(Query *parse)
 {
@@ -110,6 +117,7 @@ fixupsets(Query *parse)
        return;
     define_sets(parse);
 }
+#endif
 
 /* Recursively find all of the Consts in the parsetree.  Some of
  * these may represent a set.  The value of the Const will be the
@@ -180,7 +188,7 @@ parser_typecast(Value *expr, TypeName *typename, int typlen)
     char type_string[16];
     int32 len;
     char *cp = NULL;
-    char *const_string; 
+    char *const_string = NULL
     bool string_palloced = false;
 
     switch(nodeTag(expr)) {
@@ -297,7 +305,7 @@ parser_typecast2(Node *expr, int exprType, Type tp, int typlen)
     int32 len = tlen(tp);
     char *cp = NULL;
     
-    char *const_string; 
+    char *const_string = NULL
     bool string_palloced = false;
 
     Assert(IsA(expr,Const));
index 7d58582..da00e7e 100644 (file)
@@ -33,10 +33,10 @@ char *Sysfunc_system_date(void)
        time(&cur_time_secs);
        cur_time_expanded = localtime(&cur_time_secs);
 #if defined(EUROPEAN_DATES)
-       sprintf(buf, "%02.2d-%02.2d-%04.4d", cur_time_expanded->tm_mday,
+       sprintf(buf, "%2.2d-%2.2d-%4.4d", cur_time_expanded->tm_mday,
                        cur_time_expanded->tm_mon+1, cur_time_expanded->tm_year+1900);
 #else
-       sprintf(buf, "%02.2d-%02.2d-%04.4d", cur_time_expanded->tm_mon+1,
+       sprintf(buf, "%2.2d-%2.2d-%4.4d", cur_time_expanded->tm_mon+1,
                        cur_time_expanded->tm_mday, cur_time_expanded->tm_year+1900);
 #endif
        return &buf[0];
index 072ad8d..0f65780 100644 (file)
 
 /* dynloader.c */
 
+#define SAVE_MAXPATHLEN MAXPATHLEN
+#undef MAXPATHLEN      /* prevent compiler warning */
 #include <sys/param.h>
+#undef MAXPATHLEN
+#define MAXPATHLEN SAVE_MAXPATHLEN 
+#undef SAVE_MAXPATHLEN
 
 #if _BSDI_VERSION >= 199510
 #  include <dlfcn.h>
index 0f810b8..b845a9a 100644 (file)
@@ -10,7 +10,7 @@
  *
  *
  * IDENTIFICATION
- *    $Header: /cvsroot/pgsql/src/backend/postmaster/postmaster.c,v 1.20 1996/11/03 04:48:26 scrappy Exp $
+ *    $Header: /cvsroot/pgsql/src/backend/postmaster/postmaster.c,v 1.21 1996/11/08 05:57:41 momjian Exp $
  *
  * NOTES
  *
  *
  *-------------------------------------------------------------------------
  */
+                               /* moved here to prevent double define */
+#include <sys/param.h>         /* for MAXHOSTNAMELEN on most */
+#ifndef MAXHOSTNAMELEN
+#include <netdb.h>             /* for MAXHOSTNAMELEN on some */
+#endif
+
 #include "postgres.h"
 
+#include <signal.h>            /* for other stuff */
 #include "libpq/pqsignal.h"    /* substitute for <signal.h> */
-
 #include <string.h>
 #include <stdlib.h>
 
 #include <sys/types.h>         /* for fd_set stuff */
 #include <sys/stat.h>          /* for umask */
 #include <sys/time.h>
-#include <sys/param.h>         /* for MAXHOSTNAMELEN on most */
-#ifndef MAXHOSTNAMELEN
-#include <netdb.h>             /* for MAXHOSTNAMELEN on some */
-#endif
 #include <sys/socket.h>
 #if defined(USE_LIMITS_H)
 # include <machine/limits.h>
@@ -1098,8 +1100,8 @@ DoExec(StartupInfo *packet, int portFd)
     av[ac] = (char *) NULL;
     
     if (DebugLvl > 1) {
-       fprintf(stderr, "%s child[%d]: execv(",
-               progname, getpid());
+       fprintf(stderr, "%s child[%ld]: execv(",
+               progname, (long)getpid());
        for (i = 0; i < ac; ++i)
            fprintf(stderr, "%s, ", av[i]);
        fprintf(stderr, ")\n");
@@ -1166,10 +1168,10 @@ dumpstatus(SIGNAL_ARGS)
        Port *port = DLE_VAL(curr);
        
        fprintf(stderr, "%s: dumpstatus:\n", progname);
-       fprintf(stderr, "\tsock %d: nBytes=%d, laddr=0x%x, raddr=0x%x\n",
+       fprintf(stderr, "\tsock %d: nBytes=%d, laddr=0x%lx, raddr=0x%lx\n",
                port->sock, port->nBytes, 
-               port->laddr, 
-               port->raddr);
+               port->laddr.sin_addr.s_addr
+               port->raddr.sin_addr.s_addr);
        curr = DLGetSucc(curr);
     }
 }
index 88445cd..d59e71d 100644 (file)
@@ -47,6 +47,7 @@ static char sccsid[] = "@(#)regcomp.c 8.5 (Berkeley) 3/20/94";
 #include <ctype.h>
 #include <limits.h>
 #include <stdlib.h>
+#include <assert.h>
 
 #include <regex/regex.h>   
 #include <regex/utils.h>
@@ -284,8 +285,8 @@ register struct parse *p;
 int stop;                      /* character this ERE should end at */
 {
        register char c;
-       register sopno prevback;
-       register sopno prevfwd;
+       register sopno prevback = 0;
+       register sopno prevfwd = 0;
        register sopno conc;
        register int first = 1;         /* is this the first alternative? */
 
@@ -1592,8 +1593,8 @@ struct parse *p;
 register struct re_guts *g;
 {
        register sop *scan;
-       sop *start;
-       register sop *newstart;
+       sop *start = 0;
+       register sop *newstart = 0;
        register sopno newlen;
        register sop s;
        register char *cp;
index dbfcc25..fef668f 100644 (file)
@@ -47,6 +47,7 @@ static char sccsid[] = "@(#)regerror.c        8.4 (Berkeley) 3/20/94";
 #include <ctype.h>
 #include <limits.h>
 #include <stdlib.h>
+#include <assert.h>
 
 #include <regex/regex.h>
 #include <regex/utils.h>
index a34f3f8..115a176 100644 (file)
@@ -54,6 +54,7 @@ static char sccsid[] = "@(#)regexec.c 8.3 (Berkeley) 3/20/94";
 #include <string.h>
 #include <limits.h>
 #include <ctype.h>
+#include <assert.h>
 
 #include <regex/regex.h>
 #include <regex/utils.h>
index 64f6b1e..2ae8bcc 100644 (file)
@@ -7,7 +7,7 @@
  *
  *
  * IDENTIFICATION
- *    $Header: /cvsroot/pgsql/src/backend/rewrite/rewriteSupport.c,v 1.2 1996/10/11 03:25:00 scrappy Exp $
+ *    $Header: /cvsroot/pgsql/src/backend/rewrite/rewriteSupport.c,v 1.3 1996/11/08 05:58:06 momjian Exp $
  *
  *-------------------------------------------------------------------------
  */
@@ -36,6 +36,7 @@
  *     given a rule oid, look it up and return the rule-event-qual and
  *     list of parsetrees for the rule (in parseTrees)
  */
+#ifdef NOT_USED
 static Node *
 RuleIdGetActionInfo(Oid ruleoid, bool *instead_flag, Query **parseTrees)
 {
@@ -84,6 +85,7 @@ RuleIdGetActionInfo(Oid ruleoid, bool *instead_flag, Query **parseTrees)
     *parseTrees = ruleparse;
     return rule_evqual;
 }
+#endif
 
 int
 IsDefinedRewriteRule(char *ruleName)
index a26611f..cf017fa 100644 (file)
@@ -7,7 +7,7 @@
  *
  *
  * IDENTIFICATION
- *    $Header: /cvsroot/pgsql/src/backend/storage/buffer/buf_init.c,v 1.2 1996/11/03 04:56:58 scrappy Exp $
+ *    $Header: /cvsroot/pgsql/src/backend/storage/buffer/buf_init.c,v 1.3 1996/11/08 05:58:09 momjian Exp $
  *
  *-------------------------------------------------------------------------
  */
@@ -31,6 +31,7 @@
 #include "storage/lmgr.h"
 #include "miscadmin.h"
 #include "utils/builtins.h"
+#include "utils/dynahash.h"
 #include "utils/hsearch.h"
 #include "utils/memutils.h"
 #include "executor/execdebug.h"        /* for NDirectFileRead */
index dccee66..007f727 100644 (file)
@@ -7,7 +7,7 @@
  *
  *
  * IDENTIFICATION
- *    $Header: /cvsroot/pgsql/src/backend/storage/buffer/bufmgr.c,v 1.4 1996/11/03 04:57:00 scrappy Exp $
+ *    $Header: /cvsroot/pgsql/src/backend/storage/buffer/bufmgr.c,v 1.5 1996/11/08 05:58:11 momjian Exp $
  *
  *-------------------------------------------------------------------------
  */
@@ -48,6 +48,7 @@
  */
 #include <sys/file.h>
 #include <stdio.h>
+#include <string.h>
 #include <math.h>
 #include <signal.h>
 
@@ -69,6 +70,7 @@
 #include "utils/hsearch.h"
 #include "utils/palloc.h"
 #include "utils/memutils.h"
+#include "utils/relcache.h"
 #include "executor/execdebug.h"        /* for NDirectFileRead */
 #include "catalog/catalog.h"
 
index 627dba9..b79f23e 100644 (file)
  *
  *
  * IDENTIFICATION
- *    $Header: /cvsroot/pgsql/src/backend/storage/buffer/localbuf.c,v 1.2 1996/11/03 04:57:03 scrappy Exp $
+ *    $Header: /cvsroot/pgsql/src/backend/storage/buffer/localbuf.c,v 1.3 1996/11/08 05:58:16 momjian Exp $
  *
  *-------------------------------------------------------------------------
  */
 #include <sys/file.h>
 #include <stdio.h>
+#include <string.h>
 #include <math.h>
 #include <signal.h>
 
@@ -41,6 +42,7 @@
 #include "utils/builtins.h"
 #include "utils/hsearch.h"
 #include "utils/memutils.h"
+#include "utils/relcache.h"
 #include "executor/execdebug.h"        /* for NDirectFileRead */
 #include "catalog/catalog.h"
 
index 2bdd701..d112c98 100644 (file)
@@ -6,7 +6,7 @@
  * Copyright (c) 1994, Regents of the University of California
  *
  * IDENTIFICATION
- *    $Id: fd.c,v 1.8 1996/11/06 06:48:51 scrappy Exp $
+ *    $Id: fd.c,v 1.9 1996/11/08 05:58:21 momjian Exp $
  *
  * NOTES:
  *
 #include <sys/types.h>
 #include <fcntl.h>
 
-#include "c.h"
+#include "postgres.h"
 #include "miscadmin.h" /* for DataDir */
 #include "utils/palloc.h"
+#include "storage/fd.h"
 
 #ifdef sparc
 /*
@@ -200,7 +201,7 @@ static File fileNameOpenFile(FileName fileName, int fileFlags, int fileMode);
 static char *filepath(char *filename);
 
 int
-pg_fsync(fd)
+pg_fsync(int fd)
 {
     extern int fsyncOff;
     return fsyncOff ? 0 : fsync(fd);
index b384f6a..c512cbe 100644 (file)
@@ -7,7 +7,7 @@
  *
  *
  * IDENTIFICATION
- *    $Header: /cvsroot/pgsql/src/backend/storage/ipc/ipc.c,v 1.7 1996/11/06 06:49:01 scrappy Exp $
+ *    $Header: /cvsroot/pgsql/src/backend/storage/ipc/ipc.c,v 1.8 1996/11/08 05:58:30 momjian Exp $
  *
  * NOTES
  *
@@ -27,6 +27,7 @@
 #include <sys/types.h>
 #include <sys/file.h>
 #include <stdio.h>
+#include <string.h>
 #include <errno.h>
 
 /* XXX - the following  dependency should be moved into the defaults.mk file */
index 70c73f1..2527dae 100644 (file)
@@ -7,10 +7,14 @@
  *
  *
  * IDENTIFICATION
- *    $Header: /cvsroot/pgsql/src/backend/storage/ipc/ipci.c,v 1.3 1996/11/06 06:49:03 scrappy Exp $
+ *    $Header: /cvsroot/pgsql/src/backend/storage/ipc/ipci.c,v 1.4 1996/11/08 05:58:33 momjian Exp $
  *
  *-------------------------------------------------------------------------
  */
+#include <string.h>
+#include <sys/types.h>
+#include <sys/ipc.h>
+
 #include "postgres.h"
 
 #include "storage/ipc.h"
 #include "storage/lock.h"
 #include "miscadmin.h"         /* for DebugLvl */
 
-#if defined(sparc_solaris)
-#include <string.h>
-#include <sys/ipc.h>
-#endif
-
 /*
  * SystemPortAddressCreateMemoryKey --
  *     Returns a memory key given a port address.
index 70d3cbe..58a1e6f 100644 (file)
@@ -7,7 +7,7 @@
  *
  *
  * IDENTIFICATION
- *    $Header: /cvsroot/pgsql/src/backend/storage/ipc/shmem.c,v 1.3 1996/11/03 05:06:57 scrappy Exp $
+ *    $Header: /cvsroot/pgsql/src/backend/storage/ipc/shmem.c,v 1.4 1996/11/08 05:58:36 momjian Exp $
  *
  *-------------------------------------------------------------------------
  */
@@ -425,7 +425,7 @@ ShmemPIDDestroy(int pid)
 {
     BindingEnt *       result,item;
     bool       found;
-    SHMEM_OFFSET  location;
+    SHMEM_OFFSET  location = 0;
     
     Assert(BindingTable);
     
index 01c531e..bde4c41 100644 (file)
@@ -8,12 +8,14 @@
  *
  *
  * IDENTIFICATION
- *    $Header: /cvsroot/pgsql/src/backend/storage/large_object/inv_api.c,v 1.4 1996/11/06 06:49:17 scrappy Exp $
+ *    $Header: /cvsroot/pgsql/src/backend/storage/large_object/inv_api.c,v 1.5 1996/11/08 05:58:41 momjian Exp $
  *
  *-------------------------------------------------------------------------
  */
 #include <stdio.h>             /* for sprintf() */
+#include <string.h>
 #include <sys/file.h>
+
 #include "postgres.h"
 #include "miscadmin.h"
 #include "libpq/libpq-fs.h"
 #include "storage/itemptr.h"
 #include "storage/bufpage.h"
 #include "storage/bufmgr.h"
+#include "storage/smgr.h"
 #include "utils/rel.h"
+#include "utils/relcache.h"
 #include "utils/palloc.h"
 #include "storage/large_object.h"
+#include "storage/lmgr.h"
 #include "utils/syscache.h"
 #include "utils/builtins.h"    /* for namestrcpy() */
 #include "catalog/heap.h"
index 5567189..a7120d7 100644 (file)
@@ -7,7 +7,7 @@
  *
  *
  * IDENTIFICATION
- *    $Header: /cvsroot/pgsql/src/backend/storage/lmgr/lmgr.c,v 1.2 1996/11/03 05:07:26 scrappy Exp $
+ *    $Header: /cvsroot/pgsql/src/backend/storage/lmgr/lmgr.c,v 1.3 1996/11/08 05:58:47 momjian Exp $
  *
  *-------------------------------------------------------------------------
  */
@@ -35,6 +35,7 @@
 #include "storage/lmgr.h"
 
 #include "utils/palloc.h"
+#include "utils/mcxt.h"
 #include "utils/rel.h"
 
 #include "catalog/catname.h"
index a0777b7..c3720c4 100644 (file)
@@ -7,7 +7,7 @@
  *
  *
  * IDENTIFICATION
- *    $Header: /cvsroot/pgsql/src/backend/storage/lmgr/lock.c,v 1.4 1996/11/03 05:07:29 scrappy Exp $
+ *    $Header: /cvsroot/pgsql/src/backend/storage/lmgr/lock.c,v 1.5 1996/11/08 05:58:51 momjian Exp $
  *
  * NOTES
  *    Outside modules can create a lock table and acquire/release
  *-------------------------------------------------------------------------
  */
 #include <stdio.h>             /* for sprintf() */
+#include <string.h>
+
 #include "postgres.h"
 #include "storage/shmem.h"
 #include "storage/spin.h"
 #include "storage/proc.h"
 #include "storage/lock.h"
+#include "utils/dynahash.h"
 #include "utils/hsearch.h"
+#include "utils/memutils.h"
 #include "utils/palloc.h"
 #include "access/xact.h"
 
index 59007ed..9424f0c 100644 (file)
@@ -7,7 +7,7 @@
  *
  *
  * IDENTIFICATION
- *    $Header: /cvsroot/pgsql/src/backend/storage/lmgr/proc.c,v 1.8 1996/11/06 06:49:24 scrappy Exp $
+ *    $Header: /cvsroot/pgsql/src/backend/storage/lmgr/proc.c,v 1.9 1996/11/08 05:58:59 momjian Exp $
  *
  *-------------------------------------------------------------------------
  */
  *      This is so that we can support more backends. (system-wide semaphore
  *      sets run out pretty fast.)                -ay 4/95
  *
- * $Header: /cvsroot/pgsql/src/backend/storage/lmgr/proc.c,v 1.8 1996/11/06 06:49:24 scrappy Exp $
+ * $Header: /cvsroot/pgsql/src/backend/storage/lmgr/proc.c,v 1.9 1996/11/08 05:58:59 momjian Exp $
  */
 #include <sys/time.h>
 #ifndef WIN32
 #include <unistd.h>
 #endif /* WIN32 */
 #include <string.h>
+#include <signal.h>
 #include <sys/types.h>
+#include <sys/ipc.h>
+#include <sys/sem.h>
 
 #if defined(sparc_solaris)
 #include <sys/ipc.h>
@@ -69,6 +72,7 @@
 
 #include "storage/buf.h"       
 #include "storage/lock.h"
+#include "storage/lmgr.h"
 #include "storage/shmem.h"
 #include "storage/spin.h"
 #include "storage/proc.h"
index 77267a1..2cfc21f 100644 (file)
@@ -7,10 +7,11 @@
  *
  *
  * IDENTIFICATION
- *    $Header: /cvsroot/pgsql/src/backend/storage/page/bufpage.c,v 1.2 1996/11/03 05:07:44 scrappy Exp $
+ *    $Header: /cvsroot/pgsql/src/backend/storage/page/bufpage.c,v 1.3 1996/11/08 05:59:03 momjian Exp $
  *
  *-------------------------------------------------------------------------
  */
+#include <string.h>
 #include <sys/types.h>
 #include <sys/file.h>
 
index 9b18e44..8a41bd3 100644 (file)
@@ -7,17 +7,20 @@
  *
  *
  * IDENTIFICATION
- *    $Header: /cvsroot/pgsql/src/backend/storage/smgr/md.c,v 1.7 1996/11/04 04:53:27 momjian Exp $
+ *    $Header: /cvsroot/pgsql/src/backend/storage/smgr/md.c,v 1.8 1996/11/08 05:59:07 momjian Exp $
  *
  *-------------------------------------------------------------------------
  */
+#include <unistd.h>
 #include <stdio.h>             /* for sprintf() */
+#include <string.h>
 #include <sys/file.h>
 
 #include "postgres.h"
 #include "miscadmin.h"  /* for DataDir */
 
 #include "storage/block.h"
+#include "storage/fd.h"
 #include "storage/smgr.h"      /* where the declarations go */
 #include "storage/fd.h"
 #include "utils/mcxt.h"
index 44be231..fd6c32d 100644 (file)
@@ -10,7 +10,7 @@
  *
  *
  * IDENTIFICATION
- *    $Header: /cvsroot/pgsql/src/backend/storage/smgr/Attic/mm.c,v 1.3 1996/11/03 05:07:57 scrappy Exp $
+ *    $Header: /cvsroot/pgsql/src/backend/storage/smgr/Attic/mm.c,v 1.4 1996/11/08 05:59:11 momjian Exp $
  *
  *-------------------------------------------------------------------------
  */
@@ -25,6 +25,7 @@
 #include "storage/shmem.h"
 #include "storage/spin.h"
 
+#include "utils/dynahash.h"
 #include "utils/hsearch.h"
 #include "utils/rel.h"
 #include "utils/memutils.h"
index 6fcba64..2aaa156 100644 (file)
@@ -10,7 +10,7 @@
  *
  *
  * IDENTIFICATION
- *    $Header: /cvsroot/pgsql/src/backend/storage/smgr/smgr.c,v 1.3 1996/11/03 05:08:00 scrappy Exp $
+ *    $Header: /cvsroot/pgsql/src/backend/storage/smgr/smgr.c,v 1.4 1996/11/08 05:59:15 momjian Exp $
  *
  *-------------------------------------------------------------------------
  */
@@ -83,7 +83,6 @@ int
 smgrinit()
 {
     int i;
-    extern char *smgrout();
 
     for (i = 0; i < NSmgr; i++) {
        if (smgrsw[i].smgr_init) {
@@ -102,7 +101,6 @@ void
 smgrshutdown(int dummy)
 {
     int i;
-    extern char *smgrout();
 
     for (i = 0; i < NSmgr; i++) {
        if (smgrsw[i].smgr_shutdown) {
@@ -331,7 +329,6 @@ int
 smgrcommit()
 {
     int i;
-    extern char *smgrout();
 
     for (i = 0; i < NSmgr; i++) {
        if (smgrsw[i].smgr_commit) {
@@ -347,7 +344,6 @@ int
 smgrabort()
 {
     int i;
-    extern char *smgrout();
 
     for (i = 0; i < NSmgr; i++) {
        if (smgrsw[i].smgr_abort) {
index bc31448..4dd7fbc 100644 (file)
@@ -4,7 +4,7 @@
 #    Makefile for tcop
 #
 # IDENTIFICATION
-#    $Header: /cvsroot/pgsql/src/backend/tcop/Makefile,v 1.3 1996/11/03 06:52:27 scrappy Exp $
+#    $Header: /cvsroot/pgsql/src/backend/tcop/Makefile,v 1.4 1996/11/08 05:59:20 momjian Exp $
 #
 #-------------------------------------------------------------------------
 
@@ -14,7 +14,7 @@ include ../../Makefile.global
 INCLUDE_OPT = -I../port/$(PORTNAME) \
               -I../../include
 
-CFLAGS+=$(INCLUDE_OPT)
+CFLAGS+=$(INCLUDE_OPT) -Wno-error
 
 OBJS = aclchk.o dest.o fastpath.o postgres.o pquery.o utility.o
 
index f8d43fa..342d373 100644 (file)
@@ -7,7 +7,7 @@
  *
  *
  * IDENTIFICATION
- *    $Header: /cvsroot/pgsql/src/backend/tcop/Attic/aclchk.c,v 1.3 1996/11/03 06:52:29 scrappy Exp $
+ *    $Header: /cvsroot/pgsql/src/backend/tcop/Attic/aclchk.c,v 1.4 1996/11/08 05:59:23 momjian Exp $
  *
  * NOTES
  *    See acl.h.
 #include "access/htup.h"
 #include "access/tupmacs.h"
 #include "utils/builtins.h"
+#include "utils/memutils.h"
 #include "utils/palloc.h"
 #include "catalog/indexing.h"
 #include "catalog/catalog.h"
 #include "catalog/catname.h"
 #include "catalog/pg_group.h"
 #include "catalog/pg_operator.h"
+#include "catalog/pg_proc.h"
 #include "catalog/pg_user.h"
 #include "utils/syscache.h"
 #include "parser/catalog_utils.h"
@@ -189,7 +191,7 @@ char*
 get_groname(AclId grosysid)
 {
     HeapTuple htp;
-    char *name;
+    char *name = NULL;
 
     htp = SearchSysCacheTuple(GROSYSID, PointerGetDatum(grosysid),
                              0,0,0);
@@ -460,7 +462,7 @@ pg_ownercheck(char *usename,
              int cacheid)
 {
     HeapTuple htp;
-    AclId user_id, owner_id;
+    AclId user_id, owner_id = 0;
 
     htp = SearchSysCacheTuple(USENAME, PointerGetDatum(usename), 
                              0,0,0);
index 273caa4..611adb3 100644 (file)
@@ -7,7 +7,7 @@
  *
  *
  * IDENTIFICATION
- *    $Header: /cvsroot/pgsql/src/backend/tcop/fastpath.c,v 1.2 1996/11/03 06:52:32 scrappy Exp $
+ *    $Header: /cvsroot/pgsql/src/backend/tcop/fastpath.c,v 1.3 1996/11/08 05:59:26 momjian Exp $
  *
  * NOTES
  *    This cruft is the server side of PQfn.
@@ -57,6 +57,8 @@
  *
  *-------------------------------------------------------------------------
  */
+#include <string.h>
+
 #include "postgres.h"
 
 #include "tcop/tcopdebug.h"
index c5e1ef8..8d30dcc 100644 (file)
@@ -7,7 +7,7 @@
  *
  *
  * IDENTIFICATION
- *    $Header: /cvsroot/pgsql/src/backend/tcop/postgres.c,v 1.14 1996/11/04 04:53:31 momjian Exp $
+ *    $Header: /cvsroot/pgsql/src/backend/tcop/postgres.c,v 1.15 1996/11/08 05:59:31 momjian Exp $
  *
  * NOTES
  *    this is the "main" module of the postgres backend and
  *-------------------------------------------------------------------------
  */
 #include "libpq/pqsignal.h"    /* substitute for <signal.h> */
+
 #if defined(linux)
 #ifndef __USE_POSIX
 #define __USE_POSIX
 #endif
 #endif /* defined(linux) */
-#include <setjmp.h>
+
+#include <unistd.h>
 #include <stdio.h>
 #include <string.h>
 #include <time.h>
+#include <setjmp.h>
 #include <sys/time.h>
+#include <sys/types.h>
+#include <fcntl.h>
 #include <sys/param.h>         /* for MAXHOSTNAMELEN on most */
 #ifndef MAXHOSTNAMELEN
 #include <netdb.h>             /* for MAXHOSTNAMELEN on some */
@@ -279,7 +284,7 @@ static char
 SocketBackend(char *inBuf, int multiplexedBackend)
 {
     char qtype[2];
-    char result;
+    char result = '\0';
     
     /* ----------------
      * get input from the frontend
@@ -782,7 +787,7 @@ PostgresMain(int argc, char *argv[])
     int           flagE;
     int           flag;
     
-    char   *DBName; 
+    char   *DBName = NULL
     int    errs = 0;
     
     char   firstchar;
@@ -793,11 +798,11 @@ PostgresMain(int argc, char *argv[])
     char*  hostName;                /* the host name of the backend server */
     char   hostbuf[MAXHOSTNAMELEN];
     int    serverSock;
-    int    serverPortnum;
+    int    serverPortnum = 0;
     int    nSelected; /* number of descriptors ready from select(); */
-    int    maxFd; /* max file descriptor + 1 */
+    int    maxFd = 0; /* max file descriptor + 1 */
     fd_set rmask, basemask;
-    FrontEnd *newFE, *currentFE;
+    FrontEnd *newFE, *currentFE = NULL;
     int    numFE = 0; /* keep track of number of active frontends */
     Port   *newPort;
     int    newFd;
@@ -1157,7 +1162,8 @@ PostgresMain(int argc, char *argv[])
 #endif /* WIN32 */
     
     if (multiplexedBackend) {
-      if (StreamServerPort(hostName, serverPortnum, &serverSock) != STATUS_OK)
+      if (serverPortnum == 0 ||
+         StreamServerPort(hostName, serverPortnum, &serverSock) != STATUS_OK)
        {
          fprintf(stderr, "Postgres: cannot create stream port %d\n", serverPortnum);
          exit(1);
@@ -1250,7 +1256,7 @@ PostgresMain(int argc, char *argv[])
      */
     if (IsUnderPostmaster == false) {
        puts("\nPOSTGRES backend interactive interface");
-       puts("$Revision: 1.14 $ $Date: 1996/11/04 04:53:31 $");
+       puts("$Revision: 1.15 $ $Date: 1996/11/08 05:59:31 $");
     }
     
     /* ----------------
@@ -1503,7 +1509,7 @@ ShowUsage()
     
     fprintf(StatFp, "! system usage stats:\n");
     fprintf(StatFp, 
-           "!\t%d.%06d elapsed %d.%06d user %d.%06d system sec\n",
+           "!\t%ld.%06ld elapsed %ld.%06ld user %ld.%06ld system sec\n",
            elapse_t.tv_sec - Save_t.tv_sec,
            elapse_t.tv_usec - Save_t.tv_usec,
            r.ru_utime.tv_sec - Save_r.ru_utime.tv_sec,
@@ -1511,7 +1517,7 @@ ShowUsage()
            r.ru_stime.tv_sec - Save_r.ru_stime.tv_sec,
            r.ru_stime.tv_usec - Save_r.ru_stime.tv_usec);
     fprintf(StatFp,
-           "!\t[%d.%06d user %d.%06d sys total]\n",
+           "!\t[%ld.%06ld user %ld.%06ld sys total]\n",
            user.tv_sec, user.tv_usec, sys.tv_sec, sys.tv_usec);
 #ifndef NEED_RUSAGE
     fprintf(StatFp, 
index 3cd3197..e36ef73 100644 (file)
@@ -7,10 +7,12 @@
  *
  *
  * IDENTIFICATION
- *    $Header: /cvsroot/pgsql/src/backend/tcop/pquery.c,v 1.3 1996/11/03 06:52:35 scrappy Exp $
+ *    $Header: /cvsroot/pgsql/src/backend/tcop/pquery.c,v 1.4 1996/11/08 05:59:34 momjian Exp $
  *
  *-------------------------------------------------------------------------
  */
+#include <string.h>
+
 #include "postgres.h"
 
 #include "tcop/tcopdebug.h"
@@ -209,7 +211,7 @@ ProcessQueryDesc(QueryDesc *queryDesc)
     
     bool       isRetrieveIntoPortal;
     bool       isRetrieveIntoRelation;
-    char*      intoName;
+    char*      intoName = NULL;
     CommandDest dest;
     
     /* ----------------
index 8dd10bb..13bf1a5 100644 (file)
@@ -9,7 +9,7 @@
  *
  *
  * IDENTIFICATION
- *    $Header: /cvsroot/pgsql/src/backend/tcop/utility.c,v 1.5 1996/11/03 06:52:36 scrappy Exp $
+ *    $Header: /cvsroot/pgsql/src/backend/tcop/utility.c,v 1.6 1996/11/08 05:59:35 momjian Exp $
  *
  *-------------------------------------------------------------------------
  */
@@ -34,7 +34,7 @@
 #include "commands/explain.h"
 
 #include "nodes/parsenodes.h"
-#include "parse.h"
+#include "../backend/parser/parse.h"
 #include "utils/builtins.h"
 #include "utils/acl.h"
 #include "utils/palloc.h"
index 71431fd..34a379e 100644 (file)
@@ -7,7 +7,7 @@
  *
  *
  * IDENTIFICATION
- *    $Header: /cvsroot/pgsql/src/backend/utils/adt/arrayfuncs.c,v 1.9 1996/11/06 10:30:38 scrappy Exp $
+ *    $Header: /cvsroot/pgsql/src/backend/utils/adt/arrayfuncs.c,v 1.10 1996/11/08 05:59:38 momjian Exp $
  *
  *-------------------------------------------------------------------------
  */
@@ -47,15 +47,19 @@ static char *_ReadArrayStr(char *arrayStr, int nitems, int ndim, int dim[],
                           func_ptr inputproc, Oid typelem, char typdelim,
                           int typlen, bool typbyval, char typalign,
                           int *nbytes);
+#ifdef LOARRAY
 static char *_ReadLOArray(char *str, int *nbytes, int *fd, bool *chunkFlag,
                          int ndim, int dim[], int baseSize);
+#endif
 static void _CopyArrayEls(char **values, char *p, int nitems, int typlen,
                          char typalign, bool typbyval);
 static void system_cache_lookup(Oid element_type, bool input, int *typlen,
                bool *typbyval, char *typdelim, Oid *typelem, Oid *proc,
                char *typalign);
 static Datum _ArrayCast(char *value, bool byval, int len);
+#ifdef LOARRAY
 static char *_AdvanceBy1word(char *str, char **word);
+#endif
 static void _ArrayRange(int st[], int endp[], int bsize, char *destPtr,
                        ArrayType *array, int from);
 static int _ArrayClipCount(int stI[], int endpI[], ArrayType *array);
@@ -63,8 +67,6 @@ static void _LOArrayRange(int st[], int endp[], int bsize, int srcfd,
          int destfd, ArrayType *array, int isSrcLO, bool *isNull);
 static void _ReadArray (int st[], int endp[], int bsize, int srcfd, int destfd,
                       ArrayType *array, int isDestLO, bool *isNull);
-static char *_array_set(ArrayType *array, struct varlena *indx_str,
-                       struct varlena *dataPtr);
 static ArrayCastAndSet(char *src, bool typbyval, int typlen, char *dest);
 
 
@@ -90,7 +92,7 @@ array_in(char *string,                /* input array in external form */
     int i, nitems, dummy;
     int32 nbytes;
     char *dataPtr;
-    ArrayType *retval;
+    ArrayType *retval = NULL;
     int ndim, dim[MAXDIM], lBound[MAXDIM];
     char typalign;
     
@@ -407,6 +409,7 @@ _ReadArrayStr(char *arrayStr,
  * Read data about an array to be stored as a large object                    
  *----------------------------------------------------------------------------
  */
+#ifdef LOARRAY
 static char *
 _ReadLOArray(char *str,
             int *nbytes,
@@ -460,6 +463,7 @@ _ReadLOArray(char *str,
     }    
     return(retStr);
 }
+#endif
 
 static void
 _CopyArrayEls(char **values, 
@@ -659,8 +663,8 @@ array_ref(ArrayType *array,
          bool *isNull)
 {
     int i, ndim, *dim, *lb, offset, nbytes;
-    struct varlena *v;
-    char *retval;
+    struct varlena *v = NULL;
+    char *retval = NULL;
     
     if (array == (ArrayType *) NULL) RETURN_NULL;
     if (arraylen > 0) {
@@ -684,7 +688,7 @@ array_ref(ArrayType *array,
     
     if (ARR_IS_LO(array)) {
         char * lo_name;
-        int fd;
+        int fd = 0;
        
         /* We are assuming fixed element lengths here */
         offset *= elmlen;
@@ -786,8 +790,8 @@ array_clip(ArrayType *array,
 #ifdef LOARRAY
         char * lo_name;
 #endif
-       char * newname;
-        int fd, newfd, isDestLO = true, rsize;
+       char *newname = NULL;
+        int fd = 0, newfd = 0, isDestLO = true, rsize;
        
         if (len < 0) 
             elog(WARN, "array_clip: array of variable length objects not supported");  
@@ -863,7 +867,7 @@ array_clip(ArrayType *array,
 }
 
 /*-----------------------------------------------------------------------------
- * array_set :
+ * array_set  :
  *        This routine sets the value of an array location (specified by an index array)
  *        to a new value specified by "dataPtr".
  * result :
@@ -908,7 +912,7 @@ array_set(ArrayType *array,
     offset = GetOffset( n, dim, lb, indx);
     
     if (ARR_IS_LO(array)) {
-        int fd;
+        int fd = 0;
         struct varlena *v;
        
         /* We are assuming fixed element lengths here */
@@ -1017,7 +1021,7 @@ array_assgn(ArrayType *array,
             elog(WARN, "lowerIndex larger than upperIndx"); 
     
     if (ARR_IS_LO(array)) {
-        int fd, newfd;
+        int fd = 0, newfd = 0;
        
 #ifdef LOARRAY
         char * lo_name;
@@ -1156,6 +1160,7 @@ ArrayCastAndSet(char *src,
     return(inc);
 } 
 
+#ifdef LOARRAY
 static char *
 _AdvanceBy1word(char *str, char **word)
 {
@@ -1173,6 +1178,7 @@ _AdvanceBy1word(char *str, char **word)
         retstr = NULL;
     return retstr;
 }
+#endif
 
 int
 SanityCheckInput(int ndim, int n, int dim[], int lb[], int indx[])
@@ -1371,7 +1377,7 @@ _LOtransfer(char **destfd,
 {
 #define MAX_READ (512 * 1024)
 #define min(a, b) (a < b ? a : b)
-    struct varlena *v;
+    struct varlena *v = NULL;
     int tmp, inc, resid;
     
     inc = nitems*size; 
index f6d3952..f8f64a8 100644 (file)
@@ -6,11 +6,14 @@
  *
  *
  * IDENTIFICATION
- *    $Header: /cvsroot/pgsql/src/backend/utils/adt/Attic/chunk.c,v 1.3 1996/11/06 10:30:40 scrappy Exp $
+ *    $Header: /cvsroot/pgsql/src/backend/utils/adt/Attic/chunk.c,v 1.4 1996/11/08 05:59:40 momjian Exp $
  *
  *-------------------------------------------------------------------------
  */
 #include <ctype.h>
+#include <sys/types.h>
+#include <fcntl.h>
+
 #include "postgres.h"
 
 #include <libpq/be-fsstubs.h>
@@ -46,12 +49,14 @@ static int _FindBestChunk(int size, int dmax[], int dbest[], int dim,
                          int A[MAXPAT][MAXDIM+1], int N);
 static int get_next(int d[], int k, int C, int dmax[]);
 static void initialize_info(CHUNK_INFO *A, int ndim, int dim[], int chunk[]);
+#ifdef LOARRAY
 static void _ConvertToChunkFile(int n, int baseSize, int dim[],        int C[],
                                int srcfd, int destfd);
 static void read_chunk(int chunk_no[], int C[], char a_chunk[], int srcfd,
                       int n, int baseSize, int PX[], int dist[]);
 static int write_chunk(struct varlena * a_chunk, int ofile);
 static int seek_and_read(int pos, int size, char buff[], int fp, int from);
+#endif
 
 /*------------------------------------------------------------------------
  * _ChunkArray ---
@@ -71,7 +76,9 @@ _ChunkArray(int fd,
            int *nbytes,
            char *chunkfile)
 {
-    int cfd;
+#ifdef LOARRAY
+int cfd = 0;
+#endif
     int chunk[MAXDIM], csize;
     bool reorgFlag;
     
@@ -86,17 +93,20 @@ _ChunkArray(int fd,
        chunkfile = _array_newLO( &cfd, fileFlag );
     else 
        cfd = LOopen(chunkfile, O_RDONLY); 
-#endif
     if (cfd < 0)
-       elog(WARN, "Enable to open chunk file");
+       elog(WARN, "Unable to open chunk file");
+#endif
+
     strcpy (cInfo.lo_name, chunkfile);
     
     /* find chunk size */
     csize = GetChunkSize(afd, ndim, dim, baseSize, chunk);
     
+#ifdef LOARRAY
     if (reorgFlag)
        /* copy data from input file to chunked file */
        _ConvertToChunkFile(ndim, baseSize, dim, chunk, fd, cfd);
+#endif
     
     initialize_info(&cInfo, ndim, dim, chunk);
     *nbytes = sizeof(CHUNK_INFO);
@@ -231,8 +241,10 @@ get_next(int d[], int k, int C, int dmax[])
     return(1);
 }
 
+#ifdef LOARRAY
 static char a_chunk[_PAGE_SIZE_ + 4];   /* 4 since a_chunk is in 
                                            varlena format */
+#endif
 
 static void
 initialize_info(CHUNK_INFO *A, int ndim, int dim[], int chunk[])
@@ -254,6 +266,7 @@ initialize_info(CHUNK_INFO *A, int ndim, int dim[], int chunk[])
  *
  *-------------------------------------------------------------------------
  */
+#ifdef LOARRAY
 static void
 _ConvertToChunkFile(int n,
                    int baseSize,
@@ -337,7 +350,7 @@ read_chunk(int chunk_no[],
 static int
 write_chunk(struct varlena * a_chunk, int ofile)
 {
-    int     got_n;
+    int     got_n = 0;
 #ifdef LOARRAY
     got_n = LOwrite (ofile, a_chunk);
 #endif
@@ -354,7 +367,7 @@ write_chunk(struct varlena * a_chunk, int ofile)
 static int
 seek_and_read(int pos, int size, char buff[], int fp, int from)
 {
-    struct varlena *v;
+    struct varlena *v = NULL;
     
     /* Assuming only one file */
     if ( lo_lseek(fp, pos, from ) < 0)
@@ -369,6 +382,7 @@ seek_and_read(int pos, int size, char buff[], int fp, int from)
     return(1);
     
 }
+#endif /* LOARRAY */
 
 /*----------------------------------------------------------------------------
  * _ReadChunkArray --
@@ -453,7 +467,7 @@ _ReadChunkArray(int st[],
         for (i = 0; i < n; range[i++] = 0);
         j = n-1; bptr *= bsize;
         if (isDestLO) { 
-            if (lo_lseek(destfp, bptr, SEEK_SET) < 0)
+            if (lo_lseek((int)destfp, bptr, SEEK_SET) < 0)
                RETURN_NULL;
         }
         else 
@@ -480,7 +494,7 @@ _ReadChunkArray(int st[],
             block_seek += cdist[j];
             bptr += adist[j]*bsize;
             if (isDestLO) { 
-                if (lo_lseek(destfp, bptr, SEEK_SET) < 0)
+                if (lo_lseek((int)destfp, bptr, SEEK_SET) < 0)
                    RETURN_NULL;
             }
             else 
index f833e58..11efd89 100644 (file)
@@ -6,7 +6,7 @@
  *
  *
  * IDENTIFICATION
- *    $Header: /cvsroot/pgsql/src/backend/utils/adt/datum.c,v 1.2 1996/11/06 06:49:47 scrappy Exp $
+ *    $Header: /cvsroot/pgsql/src/backend/utils/adt/datum.c,v 1.3 1996/11/08 05:59:41 momjian Exp $
  *
  *-------------------------------------------------------------------------
  */
@@ -51,7 +51,7 @@ datumGetSize(Datum value, Oid type, bool byVal, Size len)
 {
     
     struct varlena *s;
-    Size size;
+    Size size = 0;
     
     if (byVal) {
        if (len >= 0 && len <= sizeof(Datum)) {
index 351a8e7..7b5a1b8 100644 (file)
@@ -7,7 +7,7 @@
  *
  *
  * IDENTIFICATION
- *    $Header: /cvsroot/pgsql/src/backend/utils/adt/Attic/filename.c,v 1.4 1996/11/06 10:30:51 scrappy Exp $
+ *    $Header: /cvsroot/pgsql/src/backend/utils/adt/Attic/filename.c,v 1.5 1996/11/08 05:59:43 momjian Exp $
  *
  *-------------------------------------------------------------------------
  */
@@ -28,7 +28,7 @@ char *
 filename_in(char *file)
 {
     char *str, *getenv();
-    int ind;
+    int ind = 0;
     
     /*
      * XXX - HACK CITY --- REDO
index ecdfebd..5630b2f 100644 (file)
@@ -7,7 +7,7 @@
  *
  *
  * IDENTIFICATION
- *    $Header: /cvsroot/pgsql/src/backend/utils/adt/nabstime.c,v 1.6 1996/11/06 06:49:51 scrappy Exp $
+ *    $Header: /cvsroot/pgsql/src/backend/utils/adt/nabstime.c,v 1.7 1996/11/08 05:59:45 momjian Exp $
  *
  *-------------------------------------------------------------------------
  */
@@ -589,8 +589,9 @@ qmktime(struct tm *tp)
      * correction
      */
     if (day > nmdays[mon])
-       if (mon != 2 || year % 4 == 0 &&
-           (year % 100 != 0 || year % 400 == 0) && day > 29)
+       if (mon != 2 ||
+           (year % 4 == 0 &&
+           ((year % 100 != 0 || year % 400 == 0)) && day > 29))
            return -1;  /* day too large for month */
     
     /* split year into century and year-of-century */
index 63010c3..3facee2 100644 (file)
@@ -7,7 +7,7 @@
  *
  *
  * IDENTIFICATION
- *    $Header: /cvsroot/pgsql/src/backend/utils/adt/regproc.c,v 1.2 1996/11/06 06:49:59 scrappy Exp $
+ *    $Header: /cvsroot/pgsql/src/backend/utils/adt/regproc.c,v 1.3 1996/11/08 05:59:47 momjian Exp $
  *
  *-------------------------------------------------------------------------
  */
@@ -36,7 +36,7 @@ int32 regprocin(char *proname)
     HeapScanDesc       procscan;
     HeapTuple  proctup;
     ScanKeyData               key;             
-    RegProcedure       result;
+    RegProcedure       result = (Oid)0;
     bool               isnull;
     
     if (proname == NULL)
index fea1673..7ab5049 100644 (file)
@@ -9,7 +9,7 @@
  *
  *
  * IDENTIFICATION
- *    $Header: /cvsroot/pgsql/src/backend/utils/adt/Attic/sets.c,v 1.2 1996/11/06 06:50:01 scrappy Exp $
+ *    $Header: /cvsroot/pgsql/src/backend/utils/adt/Attic/sets.c,v 1.3 1996/11/08 05:59:49 momjian Exp $
  *
  *-------------------------------------------------------------------------
  */
@@ -44,7 +44,7 @@ SetDefine(char *querystr, char *typename)
     char *procname = GENERICSETNAME;
     char *fileName = "-";
     char realprocname[16];
-    HeapTuple tup, newtup;
+    HeapTuple tup, newtup = NULL;
     Form_pg_proc proc;
     Relation procrel;
     int i;
index 230f987..4e3d4e2 100644 (file)
@@ -7,7 +7,7 @@
  *
  *
  * IDENTIFICATION
- *    $Header: /cvsroot/pgsql/src/backend/utils/adt/varlena.c,v 1.7 1996/11/06 06:50:07 scrappy Exp $
+ *    $Header: /cvsroot/pgsql/src/backend/utils/adt/varlena.c,v 1.8 1996/11/08 05:59:51 momjian Exp $
  *
  *-------------------------------------------------------------------------
  */
@@ -133,7 +133,7 @@ byteaout(struct varlena     *vlena)
     vp = vlena->vl_dat;
     for (i = vlena->vl_len - sizeof(int32); i != 0; i--)       /* varlena? */
        if (*vp == '\\') {
-           *vp++;
+           vp++;
            *rp++ = '\\';
            *rp++ = '\\';
        } else if (isascii(*vp) && isprint(*vp))
index 1e46de1..9aefc80 100644 (file)
@@ -7,7 +7,7 @@
  *
  *
  * IDENTIFICATION
- *    $Header: /cvsroot/pgsql/src/backend/utils/cache/catcache.c,v 1.3 1996/10/24 07:59:46 scrappy Exp $
+ *    $Header: /cvsroot/pgsql/src/backend/utils/cache/catcache.c,v 1.4 1996/11/08 05:59:53 momjian Exp $
  *
  * Notes:
  *     XXX This needs to use exception.h to handle recovery when
@@ -744,7 +744,7 @@ SearchSysCache(struct catcache *cache,
     CatCTup    *nct; 
     CatCTup    *nct2; 
     Dlelem      *elt;
-    HeapTuple          ntp;
+    HeapTuple          ntp = 0;
     Buffer             buffer;
     
     Relation           relation;
index 39c7e23..bf1ae04 100644 (file)
@@ -7,7 +7,7 @@
  *
  *
  * IDENTIFICATION
- *    $Header: /cvsroot/pgsql/src/backend/utils/cache/inval.c,v 1.2 1996/11/06 10:31:24 scrappy Exp $
+ *    $Header: /cvsroot/pgsql/src/backend/utils/cache/inval.c,v 1.3 1996/11/08 05:59:55 momjian Exp $
  *
  * Note - this code is real crufty...
  *
@@ -449,7 +449,7 @@ RelationInvalidateRelationCache(Relation relation,
                                void (*function)())
 {
     Oid        relationId;
-    Oid        objectId;
+    Oid        objectId = (Oid)0;
     
     /* ----------------
      * get the relation object id
index 17440ec..fca7ee3 100644 (file)
@@ -7,7 +7,7 @@
  *
  *
  * IDENTIFICATION
- *    $Header: /cvsroot/pgsql/src/backend/utils/error/elog.c,v 1.8 1996/11/06 10:31:33 scrappy Exp $
+ *    $Header: /cvsroot/pgsql/src/backend/utils/error/elog.c,v 1.9 1996/11/08 05:59:57 momjian Exp $
  *
  *-------------------------------------------------------------------------
  */
@@ -58,7 +58,10 @@ elog(int lev, const char *fmt, ... )
 #ifndef PG_STANDALONE
     extern     FILE    *Pfout;
 #endif /* !PG_STANDALONE */
-    time_t             tim, time();
+    time_t     time();
+#ifdef ELOG_TIMESTAMPS
+    time_t     tim;
+#endif
     int                len;
     int                i = 0;
     
@@ -231,7 +234,7 @@ DebugFileOpen()
     fd = fileno(stderr);
     if (fcntl(fd, F_GETFD, 0) < 0) {
        sprintf(OutputFileName, "%s/pg.errors.%d",
-               GetPGData(), getpid());
+               GetPGData(), (int)getpid());
        fd = open(OutputFileName, O_CREAT|O_APPEND|O_WRONLY, 0666);
     }
 #endif /* WIN32 */    
index 6ae2769..99fb7d8 100644 (file)
@@ -7,7 +7,7 @@
  *
  *
  * IDENTIFICATION
- *    $Header: /cvsroot/pgsql/src/backend/utils/fmgr/fmgr.c,v 1.1.1.1 1996/07/09 06:22:08 scrappy Exp $
+ *    $Header: /cvsroot/pgsql/src/backend/utils/fmgr/fmgr.c,v 1.2 1996/11/08 06:00:14 momjian Exp $
  *
  *-------------------------------------------------------------------------
  */
@@ -113,7 +113,7 @@ fmgr_c(func_ptr user_fn,
 void
 fmgr_info(Oid procedureId, func_ptr *function, int *nargs)
 {
-    func_ptr           user_fn;
+    func_ptr           user_fn = NULL;
     FmgrCall           *fcp;
     HeapTuple          procedureTuple;
     FormData_pg_proc   *procedureStruct;
index f62f2ad..f5ac53b 100644 (file)
@@ -7,7 +7,7 @@
  *
  *
  * IDENTIFICATION
- *    $Header: /cvsroot/pgsql/src/backend/utils/hash/dynahash.c,v 1.3 1996/11/06 10:31:43 scrappy Exp $
+ *    $Header: /cvsroot/pgsql/src/backend/utils/hash/dynahash.c,v 1.4 1996/11/08 06:00:23 momjian Exp $
  *
  *-------------------------------------------------------------------------
  */
@@ -43,6 +43,7 @@
 # include      <sys/types.h>
 # include      <string.h>
 # include      "postgres.h"
+# include      "utils/dynahash.h"
 # include      "utils/hsearch.h"
 #ifndef FRONTEND
 # include      "utils/mcxt.h"
@@ -65,7 +66,6 @@
  */
 static long *DynaHashAlloc(unsigned int size);
 static void DynaHashFree(Pointer ptr);
-static int hash_clear(HTAB *hashp);
 static uint32 call_hash(HTAB *hashp, char *k, int len);
 static SEG_OFFSET seg_alloc(HTAB *hashp);
 static int bucket_alloc(HTAB *hashp);
@@ -352,14 +352,6 @@ init_htab (HTAB *hashp, int nelem)
 
 /********************** DESTROY ROUTINES ************************/
 
-static int
-hash_clear(HTAB *hashp)
-{
-    elog(NOTICE,"hash_clear not implemented\n");
-    return 0;
-}
-
-
 void
 hash_destroy (HTAB     *hashp)
 {
index 430bfb0..c4fdbd8 100644 (file)
@@ -7,7 +7,7 @@
  *
  *
  * IDENTIFICATION
- *    $Header: /cvsroot/pgsql/src/backend/utils/init/postinit.c,v 1.4 1996/11/06 10:31:59 scrappy Exp $
+ *    $Header: /cvsroot/pgsql/src/backend/utils/init/postinit.c,v 1.5 1996/11/08 06:00:33 momjian Exp $
  *
  * NOTES
  *     InitPostgres() is the function called from PostgresMain
@@ -325,7 +325,7 @@ InitCommunication()
     char *getenv();    /* XXX style */
     char *postid;
     char *postport;
-    IPCKey     key;
+    IPCKey     key = 0;
     
     /* ----------------
      * try and get the backend tag from POSTID
index 5b6ca20..5e6b409 100644 (file)
@@ -7,7 +7,7 @@
  *
  *
  * IDENTIFICATION
- *    $Header: /cvsroot/pgsql/src/backend/utils/mmgr/aset.c,v 1.2 1996/11/06 10:32:04 scrappy Exp $
+ *    $Header: /cvsroot/pgsql/src/backend/utils/mmgr/aset.c,v 1.3 1996/11/08 06:00:48 momjian Exp $
  *
  * NOTE
  *    XXX This is a preliminary implementation which lacks fail-fast
@@ -368,7 +368,7 @@ AllocPointerGetNext(AllocPointer pointer)
 void
 AllocPointerDump(AllocPointer pointer)
 {
-    printf("\t%-10d@ %0#x\n", ((long*)pointer)[-1], pointer); /* XXX */
+    printf("\t%-10ld@ %0#lx\n", ((long*)pointer)[-1], (long)pointer); /* XXX */
 }
 
 /*
index d9095af..e03948f 100644 (file)
@@ -7,7 +7,7 @@
  *
  *
  * IDENTIFICATION
- *    $Header: /cvsroot/pgsql/src/backend/utils/mmgr/mcxt.c,v 1.1.1.1 1996/07/09 06:22:09 scrappy Exp $
+ *    $Header: /cvsroot/pgsql/src/backend/utils/mmgr/mcxt.c,v 1.2 1996/11/08 06:00:54 momjian Exp $
  *
  *-------------------------------------------------------------------------
  */
@@ -77,8 +77,9 @@ static Pointer GlobalMemoryRealloc(GlobalMemory this, Pointer pointer,
                                   Size size);
 static char *GlobalMemoryGetName(GlobalMemory this);
 static void GlobalMemoryDump(GlobalMemory this);
+#ifdef NOT_USED
 static void DumpGlobalMemories(void);
-
+#endif
 
 /*
  * Global Memory Methods
@@ -493,6 +494,7 @@ GlobalMemoryDump(GlobalMemory this)
  * Exceptions:
  *     ???
  */
+#ifdef NOT_USED
 static void
 DumpGlobalMemories()
 {
@@ -507,4 +509,4 @@ DumpGlobalMemories()
                                                        &context->elemData);
     }
 }
-
+#endif
index 9dd621e..f91d1f5 100644 (file)
@@ -7,7 +7,7 @@
  *
  *
  * IDENTIFICATION
- *    $Header: /cvsroot/pgsql/src/backend/utils/mmgr/portalmem.c,v 1.2 1996/11/03 06:54:25 scrappy Exp $
+ *    $Header: /cvsroot/pgsql/src/backend/utils/mmgr/portalmem.c,v 1.3 1996/11/08 06:00:57 momjian Exp $
  *
  *-------------------------------------------------------------------------
  */
@@ -465,6 +465,7 @@ AtEOXact_portals()
  *     PortalDump
  * ----------------
  */
+#ifdef NOT_USED
 static void
 PortalDump(Portal *thisP)
 {
@@ -473,11 +474,13 @@ PortalDump(Portal *thisP)
     PortalVariableMemoryDump(PortalGetVariableMemory(*thisP));
     PortalHeapMemoryDump(PortalGetHeapMemory(*thisP));
 }
+#endif
 
 /* ----------------
  *     DumpPortals
  * ----------------
  */
+#ifdef NOT_USED
 static void
 DumpPortals()
 {
@@ -485,7 +488,8 @@ DumpPortals()
     
     HashTableWalk(PortalHashTable, PortalDump, 0);
 }
-
+#endif
 /* ----------------------------------------------------------------
  *                public portal interface functions
  * ----------------------------------------------------------------
index d7b4704..0c35d51 100644 (file)
@@ -20,7 +20,7 @@
  *
  *
  * IDENTIFICATION
- *    $Header: /cvsroot/pgsql/src/bin/pg_dump/pg_dump.c,v 1.12 1996/11/04 04:00:02 momjian Exp $
+ *    $Header: /cvsroot/pgsql/src/bin/pg_dump/pg_dump.c,v 1.13 1996/11/08 06:01:03 momjian Exp $
  *
  * Modifications - 6/10/96 - dave@bensoft.com - version 1.13.dhb
  *
@@ -1557,7 +1557,6 @@ dumpTuples(PGresult *res, FILE *fout, int* attrmap)
 void
 setMaxOid(FILE *fout)
 {
-    char query[255];
     PGresult *res;
     Oid max_oid;
     
@@ -1592,7 +1591,7 @@ setMaxOid(FILE *fout)
            g_comment_start,  max_oid, g_comment_end);
     fprintf(fout, "CREATE TABLE pgdump_oid (dummy int4);\n");
     fprintf(fout, "COPY pgdump_oid WITH OIDS FROM stdin;\n");
-    fprintf(fout, "%-ld\t0\n", max_oid);
+    fprintf(fout, "%-d\t0\n", max_oid);
     fprintf(fout, "\\.\n");
     fprintf(fout, "DROP TABLE pgdump_oid;\n");
 }      
index 251f8c0..4364fc1 100644 (file)
@@ -9,7 +9,7 @@
  *
  *
  * IDENTIFICATION
- *    $Header: /cvsroot/pgsql/src/bin/pg_id/Attic/pg_id.c,v 1.2 1996/09/16 06:34:40 scrappy Exp $
+ *    $Header: /cvsroot/pgsql/src/bin/pg_id/Attic/pg_id.c,v 1.3 1996/11/08 06:01:12 momjian Exp $
  *
  *-------------------------------------------------------------------------
  */
@@ -46,9 +46,9 @@ main(int argc, char **argv)
            printf("NOUSER\n");
            exit(1);
        }
-       printf("%d\n", pw->pw_uid);
+       printf("%ld\n", (long)pw->pw_uid);
     } else {
-       printf("%d\n", getuid());
+       printf("%ld\n", (long)getuid());
     }
 
     exit(0);
index c213379..e09cd3c 100644 (file)
@@ -7,10 +7,11 @@
  *
  *
  * IDENTIFICATION
- *    $Header: /cvsroot/pgsql/src/bin/pg_version/Attic/pg_version.c,v 1.3 1996/09/19 19:58:27 scrappy Exp $
+ *    $Header: /cvsroot/pgsql/src/bin/pg_version/Attic/pg_version.c,v 1.4 1996/11/08 06:01:17 momjian Exp $
  *
  *-------------------------------------------------------------------------
  */
+#include <stdlib.h>
 #include <stdio.h>
 
 int Noversion = 0;
index 9e2dd4d..2fd82e9 100644 (file)
@@ -7,7 +7,7 @@
 #
 #
 # IDENTIFICATION
-#    $Header: /cvsroot/pgsql/src/bin/psql/Makefile,v 1.8 1996/11/02 09:53:15 bryanh Exp $
+#    $Header: /cvsroot/pgsql/src/bin/psql/Makefile,v 1.9 1996/11/08 06:01:27 momjian Exp $
 #
 #-------------------------------------------------------------------------
 
@@ -65,10 +65,10 @@ endif
 
 all: psql
 
-psql: $(OBJS) $(LIBPQDIR)/libpq.a
-       $(CC) $(LDFLAGS) -o psql -L$(LIBPQDIR) $(OBJS) -lpq $(LD_ADD)
+psql: $(OBJS) $(LIBPQDIR)/obj/libpq.a
+       $(CC) $(LDFLAGS) -o psql -L$(LIBPQDIR)/obj $(OBJS) -lpq $(LD_ADD)
 
-$(srcdir)/libpq/libpq.a:
+$(srcdir)/libpq/obj/libpq.a:
        $(MAKE) -C $(LIBPQDIR) libpq.a
 
 install:
index 5cf3762..95a111f 100644 (file)
@@ -7,17 +7,19 @@
  *
  *
  * IDENTIFICATION
- *    $Header: /cvsroot/pgsql/src/bin/psql/Attic/psql.c,v 1.24 1996/11/04 09:17:55 bryanh Exp $
+ *    $Header: /cvsroot/pgsql/src/bin/psql/Attic/psql.c,v 1.25 1996/11/08 06:01:33 momjian Exp $
  *
  *-------------------------------------------------------------------------
  */
 #include <stdio.h>
 #include <string.h>
 #include <signal.h>
+#include <errno.h>
 #include <sys/types.h>
 #include <sys/stat.h>
 #include <unistd.h>
 #include <fcntl.h>
+#include "postgres.h"
 #include "libpq-fe.h"
 #include "stringutils.h"
 
@@ -800,7 +802,7 @@ do_edit(const char *filename_arg, char *query, int *retcode_p) {
         fname=(char *)filename_arg;
         error=false;
     } else {
-        sprintf(tmp, "/tmp/psql.%d.%d", geteuid(), getpid());
+        sprintf(tmp, "/tmp/psql.%ld.%ld", (long)geteuid(), (long)getpid());
         fname=tmp;
         unlink(tmp);
         if (ql > 0) {
index de18054..656bfe3 100644 (file)
@@ -6,14 +6,16 @@
  *
  * Copyright (c) 1994, Regents of the University of California
  *
- * $Id: bootstrap.h,v 1.2 1996/11/06 10:29:05 scrappy Exp $
+ * $Id: bootstrap.h,v 1.3 1996/11/08 06:01:45 momjian Exp $
  *
  *-------------------------------------------------------------------------
  */
 #ifndef BOOTSTRAP_H
 #define BOOTSTRAP_H
 
-
+#include "access/funcindex.h"
+#include "access/itup.h"
+#include "utils/rel.h"
 
 #define        MAXATTR 40              /* max. number of attributes in a relation */
 
@@ -37,7 +39,7 @@ extern void index_register(char *heap,
                           uint16 nparams,
                           Datum *params,
                           FuncIndexInfo *finfo,
-                          PredInfo *predInfo);
+                          PredInfo *predInfo);
 
 extern void err_out(void);
 extern void InsertOneTuple(Oid objectid);
index d734651..c572c64 100644 (file)
@@ -6,13 +6,14 @@
  *
  * Copyright (c) 1994, Regents of the University of California
  *
- * $Id: async.h,v 1.3 1996/11/06 10:29:30 scrappy Exp $
+ * $Id: async.h,v 1.4 1996/11/08 06:01:49 momjian Exp $
  *
  *-------------------------------------------------------------------------
  */
 #ifndef        ASYNC_H
 #define        ASYNC_H
 
+#include <nodes/memnodes.h>
 
 extern void Async_NotifyHandler(SIGNAL_ARGS);
 extern void Async_Notify(char *relname);
index d781c4d..4cc9e37 100644 (file)
 /* found in function aclparse() in src/backend/utils/adt/acl.c */
 /* #define ACLDEBUG */
 
-/* found in src/backend/utils/adt/arrayfuncs.c */
+/* found in src/backend/utils/adt/arrayfuncs.c
+   code seems broken without it, Bruce Momjian */
 /* #define LOARRAY */
 
 /* This is the time, in seconds, at which a given backend server
index ea54dee..04c5f5d 100644 (file)
@@ -6,13 +6,16 @@
  *
  * Copyright (c) 1994, Regents of the University of California
  *
- * $Id: locks.h,v 1.2 1996/11/06 10:30:59 scrappy Exp $
+ * $Id: locks.h,v 1.3 1996/11/08 06:02:00 momjian Exp $
  *
  *-------------------------------------------------------------------------
  */
 #ifndef        LOCKS_H
 #define        LOCKS_H
 
+#include "nodes/nodes.h"
+#include "nodes/parsenodes.h"
+#include "rewrite/prs2lock.h"
 
 extern List *matchLocks(CmdType event, RuleLock *rulelocks, int varno,
                        Query *parsetree);
index bb18cd0..74fb018 100644 (file)
@@ -6,7 +6,7 @@
  *
  * Copyright (c) 1994, Regents of the University of California
  *
- * $Id: fd.h,v 1.4 1996/11/04 07:45:53 scrappy Exp $
+ * $Id: fd.h,v 1.5 1996/11/08 06:02:12 momjian Exp $
  *
  *-------------------------------------------------------------------------
  */
@@ -85,5 +85,6 @@ extern void AllocateFile(void);
 extern void FreeFile(void);
 extern void closeAllVfds(void);
 extern void closeOneVfd(void);
+extern int pg_fsync(int fd);
 
 #endif /* FD_H */
index 4f3398c..097ecb3 100644 (file)
@@ -6,7 +6,7 @@
  *
  * Copyright (c) 1994, Regents of the University of California
  *
- * $Id: lmgr.h,v 1.3 1996/11/05 06:10:59 scrappy Exp $
+ * $Id: lmgr.h,v 1.4 1996/11/08 06:02:18 momjian Exp $
  *
  *-------------------------------------------------------------------------
  */
@@ -78,4 +78,7 @@ extern bool SingleLockReln(LockInfo linfo, LOCKT lockt, int action);
 extern bool SingleLockPage(LockInfo linfo, ItemPointer tidPtr,
                           LOCKT lockt, int action);
 
+/* proc.c */
+extern void InitProcGlobal(IPCKey key);
+
 #endif /* LMGR_H */
index c6dbd08..0e3eb4c 100644 (file)
@@ -6,7 +6,7 @@
  *
  * Copyright (c) 1994, Regents of the University of California
  *
- * $Id: smgr.h,v 1.2 1996/11/05 06:11:07 scrappy Exp $
+ * $Id: smgr.h,v 1.3 1996/11/08 06:02:22 momjian Exp $
  *
  *-------------------------------------------------------------------------
  */
@@ -82,4 +82,7 @@ extern int mmcommit(void);
 extern int mmabort(void);
 extern int MMShmemSize(void);
 
+/* smgrtype.c */
+char *smgrout(int2 i);
+
 #endif /* SMGR_H */
index 7d35ed0..bb00e63 100644 (file)
@@ -7,7 +7,7 @@
 #
 #
 # IDENTIFICATION
-#    $Header: /cvsroot/pgsql/src/interfaces/libpq/Makefile,v 1.12 1996/11/04 06:32:59 bryanh Exp $
+#    $Header: /cvsroot/pgsql/src/interfaces/libpq/Makefile,v 1.13 1996/11/08 06:02:25 momjian Exp $
 #
 #-------------------------------------------------------------------------
 
@@ -33,21 +33,22 @@ VPATH:=$(VPATH):../backend/port/$(PORTNAME)
 OBJS+= getcwd.o putenv.o
 endif
 
-ifdef LINUX_ELF
-shlib := libpq.so.1
-else
 shlib := 
+ifdef LINUX_ELF
+ifeq ($(PORTNAME), linux)
+shlib := obj/libpq.so.1
+endif
 endif
 
-all: libpq.a $(shlib) postgres.h c.h
+all: obj/libpq.a $(shlib) postgres.h c.h
 
-libpq.a: $(OBJS)
+obj/libpq.a: $(OBJS)
 ifdef MK_NO_LORDER
-       $(AR) $(AROPT) libpq.a $(OBJS) 
+       $(AR) $(AROPT) obj/libpq.a $(OBJS) 
 else
-       $(AR) $(AROPT) libpq.a `lorder $(OBJS) | tsort`
+       $(AR) $(AROPT) obj/libpq.a `lorder $(OBJS) | tsort`
 endif
-       $(RANLIB) libpq.a
+       $(RANLIB) obj/libpq.a
 
 fe-lobj.o:: ../backend/fmgr.h
 
@@ -60,8 +61,8 @@ fe-lobj.o:: ../backend/fmgr.h
 ../backend/lib/dllist.o:
        $(MAKE) -C ../backend/lib dllist.o
 
-libpq.so.1: $(OBJS)
-       $(CC) $(LDFLAGS) -shared $(OBJS) -o libpq.so.1
+obj/libpq.so.1: $(OBJS)
+       $(CC) $(LDFLAGS) -shared $(OBJS) -o obj/libpq.so.1
 
 postgres.h: ../include/postgres.h
 # Note: ../backend/include/postgres.h needs to be named something different
@@ -127,17 +128,17 @@ install-shlib-dep :=
 endif
 
 install-libpq:
-       $(INSTALL) $(INSTL_LIB_OPTS) libpq.a $(DESTDIR)$(LIBDIR)/libpq.a
+       $(INSTALL) $(INSTL_LIB_OPTS) obj/libpq.a $(DESTDIR)$(LIBDIR)/libpq.a
 
 install-shlib:
-       $(INSTALL) $(INSTL_LIB_OPTS) libpq.so.1 $(DESTDIR)$(LIBDIR)/libpq.so.1
+       $(INSTALL) $(INSTL_LIB_OPTS) obj/libpq.so.1 $(DESTDIR)$(LIBDIR)/libpq.so.1
 
 depend dep:
        $(CC) -MM $(INCLUDE_OPT) *.c >depend
 
 .PHONY: clean
 clean:
-       rm -f libpq.a libpq.so.1 $(OBJS) c.h postgres.h
+       rm -f obj/libpq.a obj/libpq.so.1 $(OBJS) c.h postgres.h
 
 ifeq (depend,$(wildcard depend))
 include depend
index e8cbf14..b2c9033 100644 (file)
@@ -7,10 +7,11 @@
  *
  *
  * IDENTIFICATION
- *    $Header: /cvsroot/pgsql/src/interfaces/libpq/fe-lobj.c,v 1.2 1996/10/31 05:58:32 momjian Exp $
+ *    $Header: /cvsroot/pgsql/src/interfaces/libpq/fe-lobj.c,v 1.3 1996/11/08 06:02:28 momjian Exp $
  *
  *-------------------------------------------------------------------------
  */
+#include <unistd.h>
 #include <stdio.h>
 #include <fcntl.h>
 #include <sys/stat.h>
index 638c494..48868ef 100644 (file)
@@ -8,7 +8,7 @@
  *
  *
  * IDENTIFICATION
- *    $Header: /cvsroot/pgsql/src/interfaces/libpq/pqsignal.c,v 1.1.1.1 1996/07/09 06:22:17 scrappy Exp $
+ *    $Header: /cvsroot/pgsql/src/interfaces/libpq/pqsignal.c,v 1.2 1996/11/08 06:02:30 momjian Exp $
  *
  * NOTES
  *     This shouldn't be in libpq, but the monitor and some other
@@ -16,6 +16,8 @@
  *
  *-------------------------------------------------------------------------
  */
+#include <stdlib.h>
+
 #include "libpq/pqsignal.h"
 
 pqsigfunc