]> git.ipfire.org Git - thirdparty/postgresql.git/commitdiff
Fix a bug about automatic client_encoding setting.
authorHiroshi Inoue <inoue@tpf.co.jp>
Tue, 30 Jul 2002 00:48:02 +0000 (00:48 +0000)
committerHiroshi Inoue <inoue@tpf.co.jp>
Tue, 30 Jul 2002 00:48:02 +0000 (00:48 +0000)
src/interfaces/odbc/connection.c
src/interfaces/odbc/multibyte.c

index 45a23386e33cff0421687760ea932632e653864c..e3c0563ec2d0ecd90ae54aacebabe53ec4d24074 100644 (file)
@@ -999,6 +999,7 @@ another_version_retry:
                                if (res = CC_send_query(self, "set client_encoding to 'UTF8'", NULL, CLEAR_RESULT_ON_ABORT), res)
                                {
                                        self->client_encoding = strdup("UNICODE");
+                                       self->ccsc = pg_CS_code(self->client_encoding);
                                        QR_Destructor(res);
                                        
                                }
index 17863a9ef5fe8c2c5dd2a3401db90203cc090c5d..a31f2e9b4bd7c43fe6eb9af63da3b1876d8ac3a7 100644 (file)
@@ -401,6 +401,7 @@ CC_lookup_characterset(ConnectionClass *self)
                        if (res)
                        {
                                self->client_encoding = strdup(wenc);
+                               self->ccsc = pg_CS_code(self->client_encoding);
                                QR_Destructor(res);
                                free(encstr);
                                return;