mirror of
https://github.com/postgres/postgres.git
synced 2025-08-09 17:03:00 +03:00
Fix a bug about automatic client_encoding setting.
This commit is contained in:
@@ -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);
|
||||
|
||||
}
|
||||
|
@@ -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;
|
||||
|
Reference in New Issue
Block a user