Const fixes from D'Arcy.
This commit is contained in:
parent
ce3afccf7f
commit
a03b817373
@ -7,7 +7,7 @@
|
||||
*
|
||||
*
|
||||
* IDENTIFICATION
|
||||
* $Header: /cvsroot/pgsql/src/interfaces/libpq/fe-connect.c,v 1.89 1999/01/27 01:18:22 scrappy Exp $
|
||||
* $Header: /cvsroot/pgsql/src/interfaces/libpq/fe-connect.c,v 1.90 1999/02/04 03:20:39 momjian Exp $
|
||||
*
|
||||
*-------------------------------------------------------------------------
|
||||
*/
|
||||
@ -48,7 +48,7 @@ static PGconn *makeEmptyPGconn(void);
|
||||
static void freePGconn(PGconn *conn);
|
||||
static void closePGconn(PGconn *conn);
|
||||
static int conninfo_parse(const char *conninfo, char *errorMessage);
|
||||
static char *conninfo_getval(char *keyword);
|
||||
static const char *conninfo_getval(const char *keyword);
|
||||
static void conninfo_free(void);
|
||||
static void defaultNoticeProcessor(void *arg, const char *message);
|
||||
|
||||
@ -173,7 +173,7 @@ PGconn *
|
||||
PQconnectdb(const char *conninfo)
|
||||
{
|
||||
PGconn *conn;
|
||||
char *tmp;
|
||||
const char *tmp;
|
||||
|
||||
/* ----------
|
||||
* Allocate memory for the conn structure
|
||||
@ -285,7 +285,7 @@ PGconn *
|
||||
PQsetdbLogin(const char *pghost, const char *pgport, const char *pgoptions, const char *pgtty, const char *dbName, const char *login, const char *pwd)
|
||||
{
|
||||
PGconn *conn;
|
||||
char *tmp;
|
||||
const char *tmp;
|
||||
|
||||
/* An error message from some service we call. */
|
||||
bool error = FALSE;
|
||||
@ -1137,7 +1137,7 @@ conninfo_parse(const char *conninfo, char *errorMessage)
|
||||
char *pname;
|
||||
char *pval;
|
||||
char *buf;
|
||||
char *tmp;
|
||||
const char *tmp;
|
||||
char *cp;
|
||||
char *cp2;
|
||||
PQconninfoOption *option;
|
||||
@ -1343,8 +1343,8 @@ conninfo_parse(const char *conninfo, char *errorMessage)
|
||||
}
|
||||
|
||||
|
||||
static char *
|
||||
conninfo_getval(char *keyword)
|
||||
static const char *
|
||||
conninfo_getval(const char *keyword)
|
||||
{
|
||||
PQconninfoOption *option;
|
||||
|
||||
|
@ -9,7 +9,7 @@
|
||||
* didn't really belong there.
|
||||
*
|
||||
* IDENTIFICATION
|
||||
* $Header: /cvsroot/pgsql/src/interfaces/libpq/fe-print.c,v 1.17 1999/02/03 21:17:50 momjian Exp $
|
||||
* $Header: /cvsroot/pgsql/src/interfaces/libpq/fe-print.c,v 1.18 1999/02/04 03:20:39 momjian Exp $
|
||||
*
|
||||
*-------------------------------------------------------------------------
|
||||
*/
|
||||
@ -679,7 +679,7 @@ do_header(FILE *fout, PQprintOpt *po, const int nFields, int *fieldMax,
|
||||
p = border;
|
||||
if (po->standard)
|
||||
{
|
||||
char *fs = po->fieldSep;
|
||||
const char *fs = po->fieldSep;
|
||||
|
||||
while (*fs++)
|
||||
*p++ = '+';
|
||||
@ -691,7 +691,7 @@ do_header(FILE *fout, PQprintOpt *po, const int nFields, int *fieldMax,
|
||||
for (len = fieldMax[j] + (po->standard ? 2 : 0); len--; *p++ = '-');
|
||||
if (po->standard || (j + 1) < nFields)
|
||||
{
|
||||
char *fs = po->fieldSep;
|
||||
const char *fs = po->fieldSep;
|
||||
|
||||
while (*fs++)
|
||||
*p++ = '+';
|
||||
|
@ -6,7 +6,7 @@
|
||||
*
|
||||
* Copyright (c) 1994, Regents of the University of California
|
||||
*
|
||||
* $Id: libpq-fe.h,v 1.45 1998/10/06 14:16:49 tgl Exp $
|
||||
* $Id: libpq-fe.h,v 1.46 1999/02/04 03:20:39 momjian Exp $
|
||||
*
|
||||
*-------------------------------------------------------------------------
|
||||
*/
|
||||
@ -100,9 +100,9 @@ extern "C"
|
||||
pqbool html3; /* output html tables */
|
||||
pqbool expanded; /* expand tables */
|
||||
pqbool pager; /* use pager for output if needed */
|
||||
char *fieldSep; /* field separator */
|
||||
char *tableOpt; /* insert to HTML <table ...> */
|
||||
char *caption; /* HTML <caption> */
|
||||
const char *fieldSep; /* field separator */
|
||||
const char *tableOpt; /* insert to HTML <table ...> */
|
||||
const char *caption; /* HTML <caption> */
|
||||
char **fieldName; /* null terminated array of repalcement
|
||||
* field names */
|
||||
} PQprintOpt;
|
||||
@ -113,12 +113,12 @@ extern "C"
|
||||
*/
|
||||
typedef struct _PQconninfoOption
|
||||
{
|
||||
char *keyword; /* The keyword of the option */
|
||||
char *envvar; /* Fallback environment variable name */
|
||||
char *compiled; /* Fallback compiled in default value */
|
||||
const char *keyword; /* The keyword of the option */
|
||||
const char *envvar; /* Fallback environment variable name */
|
||||
const char *compiled; /* Fallback compiled in default value */
|
||||
char *val; /* Options value */
|
||||
char *label; /* Label for field in connect dialog */
|
||||
char *dispchar; /* Character to display for this field */
|
||||
const char *label; /* Label for field in connect dialog */
|
||||
const char *dispchar; /* Character to display for this field */
|
||||
/* in a connect dialog. Values are: */
|
||||
/* "" Display entered value as is */
|
||||
/* "*" Password field - hide value */
|
||||
|
Loading…
x
Reference in New Issue
Block a user