This is the first (of hopefully few) AIX port patches. This patch
was tested with Linux/GCC. I still have some issues with with the snprintf() function. David Hartwig
This commit is contained in:
parent
9a88848027
commit
9728ce7499
|
@ -6,7 +6,7 @@
|
||||||
*
|
*
|
||||||
*
|
*
|
||||||
* IDENTIFICATION
|
* IDENTIFICATION
|
||||||
* $Header: /cvsroot/pgsql/src/backend/commands/copy.c,v 1.54 1998/08/24 01:13:39 momjian Exp $
|
* $Header: /cvsroot/pgsql/src/backend/commands/copy.c,v 1.55 1998/08/29 04:09:23 momjian Exp $
|
||||||
*
|
*
|
||||||
*-------------------------------------------------------------------------
|
*-------------------------------------------------------------------------
|
||||||
*/
|
*/
|
||||||
|
@ -65,7 +65,7 @@ static char *CopyReadAttribute(FILE *fp, bool *isnull, char *delim, int *newline
|
||||||
static char *CopyReadAttribute(FILE *fp, bool *isnull, char *delim);
|
static char *CopyReadAttribute(FILE *fp, bool *isnull, char *delim);
|
||||||
|
|
||||||
#endif
|
#endif
|
||||||
static void CopyAttributeOut(FILE *fp, unsigned char *string, char *delim, int is_array);
|
static void CopyAttributeOut(FILE *fp, char *string, char *delim, int is_array);
|
||||||
static int CountTuples(Relation relation);
|
static int CountTuples(Relation relation);
|
||||||
|
|
||||||
extern FILE *Pfout,
|
extern FILE *Pfout,
|
||||||
|
@ -1146,9 +1146,9 @@ CopyReadAttribute(FILE *fp, bool *isnull, char *delim)
|
||||||
}
|
}
|
||||||
|
|
||||||
static void
|
static void
|
||||||
CopyAttributeOut(FILE *fp, unsigned char *server_string, char *delim, int is_array)
|
CopyAttributeOut(FILE *fp, char *server_string, char *delim, int is_array)
|
||||||
{
|
{
|
||||||
unsigned char *string;
|
char *string;
|
||||||
char c;
|
char c;
|
||||||
|
|
||||||
#ifdef MULTIBYTE
|
#ifdef MULTIBYTE
|
||||||
|
|
|
@ -7,7 +7,7 @@
|
||||||
*
|
*
|
||||||
*
|
*
|
||||||
* IDENTIFICATION
|
* IDENTIFICATION
|
||||||
* $Header: /cvsroot/pgsql/src/backend/commands/dbcommands.c,v 1.21 1998/08/24 01:13:40 momjian Exp $
|
* $Header: /cvsroot/pgsql/src/backend/commands/dbcommands.c,v 1.22 1998/08/29 04:09:24 momjian Exp $
|
||||||
*
|
*
|
||||||
*-------------------------------------------------------------------------
|
*-------------------------------------------------------------------------
|
||||||
*/
|
*/
|
||||||
|
@ -45,8 +45,8 @@ static void stop_vacuum(char *dbpath, char *dbname);
|
||||||
void
|
void
|
||||||
createdb(char *dbname, char *dbpath, int encoding)
|
createdb(char *dbname, char *dbpath, int encoding)
|
||||||
{
|
{
|
||||||
Oid db_id,
|
Oid db_id;
|
||||||
user_id;
|
int4 user_id;
|
||||||
char buf[512];
|
char buf[512];
|
||||||
char *lp,
|
char *lp,
|
||||||
loc[512];
|
loc[512];
|
||||||
|
@ -100,8 +100,8 @@ createdb(char *dbname, char *dbpath, int encoding)
|
||||||
void
|
void
|
||||||
destroydb(char *dbname)
|
destroydb(char *dbname)
|
||||||
{
|
{
|
||||||
Oid user_id,
|
int4 user_id;
|
||||||
db_id;
|
Oid db_id;
|
||||||
char *path;
|
char *path;
|
||||||
char dbpath[MAXPGPATH + 1];
|
char dbpath[MAXPGPATH + 1];
|
||||||
char buf[512];
|
char buf[512];
|
||||||
|
|
|
@ -7,7 +7,7 @@
|
||||||
*
|
*
|
||||||
*
|
*
|
||||||
* IDENTIFICATION
|
* IDENTIFICATION
|
||||||
* $Header: /cvsroot/pgsql/src/backend/optimizer/plan/planner.c,v 1.29 1998/07/20 21:18:32 momjian Exp $
|
* $Header: /cvsroot/pgsql/src/backend/optimizer/plan/planner.c,v 1.30 1998/08/29 04:09:25 momjian Exp $
|
||||||
*
|
*
|
||||||
*-------------------------------------------------------------------------
|
*-------------------------------------------------------------------------
|
||||||
*/
|
*/
|
||||||
|
@ -244,16 +244,15 @@ union_planner(Query *parse)
|
||||||
* using the same function as for a subselect in 'where' */
|
* using the same function as for a subselect in 'where' */
|
||||||
if (parse->hasSubLinks)
|
if (parse->hasSubLinks)
|
||||||
{
|
{
|
||||||
(List *) parse->havingQual =
|
parse->havingQual = SS_process_sublinks((Node *) parse->havingQual);
|
||||||
(List *) SS_process_sublinks((Node *) parse->havingQual);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/* convert the havingQual to conjunctive normal form (cnf) */
|
/* convert the havingQual to conjunctive normal form (cnf) */
|
||||||
(List *) parse->havingQual=cnfify((Expr *)(Node *) parse->havingQual,true);
|
parse->havingQual = (Node * ) cnfify((Expr *)(Node *) parse->havingQual,true);
|
||||||
|
|
||||||
/* Calculate the opfids from the opnos (=select the correct functions for
|
/* Calculate the opfids from the opnos (=select the correct functions for
|
||||||
* the used VAR datatypes) */
|
* the used VAR datatypes) */
|
||||||
(List *) parse->havingQual=fix_opids((List *) parse->havingQual);
|
parse->havingQual = (Node * ) fix_opids((List *) parse->havingQual);
|
||||||
|
|
||||||
((Agg *) result_plan)->plan.qual=(List *) parse->havingQual;
|
((Agg *) result_plan)->plan.qual=(List *) parse->havingQual;
|
||||||
|
|
||||||
|
|
|
@ -7,7 +7,7 @@
|
||||||
*
|
*
|
||||||
*
|
*
|
||||||
* IDENTIFICATION
|
* IDENTIFICATION
|
||||||
* $Header: /cvsroot/pgsql/src/backend/utils/adt/varlena.c,v 1.39 1998/07/24 03:31:43 scrappy Exp $
|
* $Header: /cvsroot/pgsql/src/backend/utils/adt/varlena.c,v 1.40 1998/08/29 04:09:27 momjian Exp $
|
||||||
*
|
*
|
||||||
*-------------------------------------------------------------------------
|
*-------------------------------------------------------------------------
|
||||||
*/
|
*/
|
||||||
|
@ -475,10 +475,10 @@ textne(text *arg1, text *arg2)
|
||||||
* Returns -1, 0 or 1
|
* Returns -1, 0 or 1
|
||||||
*/
|
*/
|
||||||
int
|
int
|
||||||
varstr_cmp(unsigned char *arg1, int len1, unsigned char *arg2, int len2)
|
varstr_cmp(char *arg1, int len1, char *arg2, int len2)
|
||||||
{
|
{
|
||||||
int result;
|
int result;
|
||||||
unsigned char *a1p, *a2p;
|
char *a1p, *a2p;
|
||||||
|
|
||||||
#ifdef USE_LOCALE
|
#ifdef USE_LOCALE
|
||||||
a1p = (unsigned char *) palloc(len1 + 1);
|
a1p = (unsigned char *) palloc(len1 + 1);
|
||||||
|
@ -518,14 +518,14 @@ varstr_cmp(unsigned char *arg1, int len1, unsigned char *arg2, int len2)
|
||||||
int
|
int
|
||||||
text_cmp(text *arg1, text *arg2)
|
text_cmp(text *arg1, text *arg2)
|
||||||
{
|
{
|
||||||
unsigned char *a1p, *a2p;
|
char *a1p, *a2p;
|
||||||
int len1, len2;
|
int len1, len2;
|
||||||
|
|
||||||
if (arg1 == NULL || arg2 == NULL)
|
if (arg1 == NULL || arg2 == NULL)
|
||||||
return ((bool) FALSE);
|
return ((bool) FALSE);
|
||||||
|
|
||||||
a1p = (unsigned char *) VARDATA(arg1);
|
a1p = VARDATA(arg1);
|
||||||
a2p = (unsigned char *) VARDATA(arg2);
|
a2p = VARDATA(arg2);
|
||||||
|
|
||||||
len1 = VARSIZE(arg1) - VARHDRSZ;
|
len1 = VARSIZE(arg1) - VARHDRSZ;
|
||||||
len2 = VARSIZE(arg2) - VARHDRSZ;
|
len2 = VARSIZE(arg2) - VARHDRSZ;
|
||||||
|
|
|
@ -6,7 +6,7 @@
|
||||||
*
|
*
|
||||||
* Copyright (c) 1994, Regents of the University of California
|
* Copyright (c) 1994, Regents of the University of California
|
||||||
*
|
*
|
||||||
* $Id: builtins.h,v 1.47 1998/08/19 02:04:03 momjian Exp $
|
* $Id: builtins.h,v 1.48 1998/08/29 04:09:29 momjian Exp $
|
||||||
*
|
*
|
||||||
* NOTES
|
* NOTES
|
||||||
* This should normally only be included by fmgr.h.
|
* This should normally only be included by fmgr.h.
|
||||||
|
@ -438,7 +438,7 @@ extern char *textout(text *vlena);
|
||||||
extern text *textcat(text *arg1, text *arg2);
|
extern text *textcat(text *arg1, text *arg2);
|
||||||
extern bool texteq(text *arg1, text *arg2);
|
extern bool texteq(text *arg1, text *arg2);
|
||||||
extern bool textne(text *arg1, text *arg2);
|
extern bool textne(text *arg1, text *arg2);
|
||||||
extern int varstr_cmp(unsigned char *arg1, int len1, unsigned char *arg2, int len2);
|
extern int varstr_cmp(char *arg1, int len1, char *arg2, int len2);
|
||||||
extern int text_cmp(text *arg1, text *arg2);
|
extern int text_cmp(text *arg1, text *arg2);
|
||||||
extern bool text_lt(text *arg1, text *arg2);
|
extern bool text_lt(text *arg1, text *arg2);
|
||||||
extern bool text_le(text *arg1, text *arg2);
|
extern bool text_le(text *arg1, text *arg2);
|
||||||
|
|
Loading…
Reference in New Issue