mirror of
https://github.com/postgres/postgres.git
synced 2025-07-28 23:42:10 +03:00
From: Tatsuo Ishii <t-ishii@sra.co.jp>
Included patches fix a portability problem of unsetenv() used in 6.4.2 multi-byte support. unsetenv() is only avaliable on FreeBSD and Linux so I decided to replace with putenv().
This commit is contained in:
@ -7,7 +7,7 @@
|
||||
*
|
||||
*
|
||||
* IDENTIFICATION
|
||||
* $Header: /cvsroot/pgsql/src/interfaces/libpq/fe-connect.c,v 1.88 1999/01/17 06:19:35 momjian Exp $
|
||||
* $Header: /cvsroot/pgsql/src/interfaces/libpq/fe-connect.c,v 1.89 1999/01/27 01:18:22 scrappy Exp $
|
||||
*
|
||||
*-------------------------------------------------------------------------
|
||||
*/
|
||||
@ -816,7 +816,7 @@ PQsetenv(PGconn *conn)
|
||||
#ifdef MULTIBYTE
|
||||
/* query server encoding */
|
||||
env = getenv(envname);
|
||||
if (!env)
|
||||
if (!env || *env == NULL)
|
||||
{
|
||||
rtn = PQexec(conn, "select getdatabaseencoding()");
|
||||
if (rtn && PQresultStatus(rtn) == PGRES_TUPLES_OK)
|
||||
|
Reference in New Issue
Block a user