提交 498d2d1e 编写于 作者: M Marc G. Fournier

From: Edmund Mergl <E.Mergl@bawue.de>

Subject: [PATCHES] libpq patch

Hi,

here is a small patch which fixes two problems:

1. libpq/libpq-fe.h:

somehow disappeared the line

#define DefaultOption ""

now compilation stops with an error complainig an
unknown DefaultOption (970508).


2. Same patch as I sent already twice, but it never made it
  into the source tree:  there is no default value for
  AuthType and Password. This way any libpq-application
  (i.e. perl-scripts) which use the function PQconnectdb
  will break with PostgreSQL-6.1. The patch simply uses
  an empty string as default value.
上级 6ef382c6
...@@ -7,7 +7,7 @@ ...@@ -7,7 +7,7 @@
* *
* *
* IDENTIFICATION * IDENTIFICATION
* $Header: /cvsroot/pgsql/src/interfaces/libpq/fe-connect.c,v 1.32 1997/05/07 03:13:50 scrappy Exp $ * $Header: /cvsroot/pgsql/src/interfaces/libpq/fe-connect.c,v 1.33 1997/05/09 03:28:49 scrappy Exp $
* *
*------------------------------------------------------------------------- *-------------------------------------------------------------------------
*/ */
...@@ -73,13 +73,13 @@ static PQconninfoOption PQconninfoOptions[] = { ...@@ -73,13 +73,13 @@ static PQconninfoOption PQconninfoOptions[] = {
/* Option-name Environment-Var Compiled-in Current value */ /* Option-name Environment-Var Compiled-in Current value */
/* Label Disp-Char */ /* Label Disp-Char */
/* ----------------- --------------- --------------- --------------- */ /* ----------------- --------------- --------------- --------------- */
{ "authtype", "PGAUTHTYPE", NULL, NULL, { "authtype", "PGAUTHTYPE", DefaultAuthtype, NULL,
"Database-Authtype", "", 20 }, "Database-Authtype", "", 20 },
{ "user", "PGUSER", NULL, NULL, { "user", "PGUSER", NULL, NULL,
"Database-User", "", 20 }, "Database-User", "", 20 },
{ "password", "PGPASSWORD", NULL, NULL, { "password", "PGPASSWORD", DefaultPassword, NULL,
"Database-Password", "", 20 }, "Database-Password", "", 20 },
{ "dbname", "PGDATABASE", NULL, NULL, { "dbname", "PGDATABASE", NULL, NULL,
......
...@@ -6,7 +6,7 @@ ...@@ -6,7 +6,7 @@
* *
* Copyright (c) 1994, Regents of the University of California * Copyright (c) 1994, Regents of the University of California
* *
* $Id: libpq-fe.h,v 1.18 1997/03/12 21:23:16 scrappy Exp $ * $Id: libpq-fe.h,v 1.19 1997/05/09 03:28:54 scrappy Exp $
* *
*------------------------------------------------------------------------- *-------------------------------------------------------------------------
*/ */
...@@ -301,6 +301,9 @@ int lo_export(PGconn *conn, Oid lobjId, char *filename); ...@@ -301,6 +301,9 @@ int lo_export(PGconn *conn, Oid lobjId, char *filename);
#define DefaultHost "localhost" #define DefaultHost "localhost"
#define DefaultTty "" #define DefaultTty ""
#define DefaultOption "" #define DefaultOption ""
#define DefaultAuthtype ""
#define DefaultPassword ""
typedef void *TUPLE; typedef void *TUPLE;
#define palloc malloc #define palloc malloc
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册