1
0
mirror of https://github.com/postgres/postgres.git synced 2025-07-20 05:03: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:
Marc G. Fournier
1999-01-27 01:18:23 +00:00
parent e27f8791f9
commit 2ae5d51668
4 changed files with 9 additions and 11 deletions

View File

@ -9,7 +9,7 @@
* didn't really belong there.
*
* IDENTIFICATION
* $Header: /cvsroot/pgsql/src/interfaces/libpq/fe-print.c,v 1.15 1998/10/06 14:16:50 tgl Exp $
* $Header: /cvsroot/pgsql/src/interfaces/libpq/fe-print.c,v 1.16 1999/01/27 01:18:23 scrappy Exp $
*
*-------------------------------------------------------------------------
*/
@ -506,7 +506,7 @@ PQmblen(unsigned char *s)
int encoding = -1;
str = getenv("PGCLIENTENCODING");
if (str)
if (str && *str != NULL)
encoding = pg_char_to_encoding(str);
if (encoding < 0)
encoding = MULTIBYTE;