diff options
author | Tom Lane <tgl@sss.pgh.pa.us> | 2006-12-24 00:57:48 +0000 |
---|---|---|
committer | Tom Lane <tgl@sss.pgh.pa.us> | 2006-12-24 00:57:48 +0000 |
commit | e9da20ab4d2f8c34130e624c7c78dffaf3119af4 (patch) | |
tree | 663d76d02f247ae5e0cec5ba7b94f9950a97a3a9 /src/include/mb/pg_wchar.h | |
parent | c957c0bac7f9785ae2a7520a9f693eeda0ff545b (diff) | |
download | postgresql-e9da20ab4d2f8c34130e624c7c78dffaf3119af4.tar.gz postgresql-e9da20ab4d2f8c34130e624c7c78dffaf3119af4.zip |
Fix machine-dependent crash in sqlchar_to_unicode(). Get rid of
bletcherous and unsafe manipulation of global encoding setting.
Clean up libxml reporting mechanism a bit (it still looks like a
dangling-pointer crash waiting to happen, though, not to mention
being far less than sane from a localization standpoint).
Diffstat (limited to 'src/include/mb/pg_wchar.h')
-rw-r--r-- | src/include/mb/pg_wchar.h | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/src/include/mb/pg_wchar.h b/src/include/mb/pg_wchar.h index 2d465a1b38b..78236c71804 100644 --- a/src/include/mb/pg_wchar.h +++ b/src/include/mb/pg_wchar.h @@ -1,4 +1,4 @@ -/* $PostgreSQL: pgsql/src/include/mb/pg_wchar.h,v 1.69 2006/10/04 00:30:09 momjian Exp $ */ +/* $PostgreSQL: pgsql/src/include/mb/pg_wchar.h,v 1.70 2006/12/24 00:57:48 tgl Exp $ */ #ifndef PG_WCHAR_H #define PG_WCHAR_H @@ -293,6 +293,8 @@ typedef struct extern int pg_mb2wchar(const char *from, pg_wchar *to); extern int pg_mb2wchar_with_len(const char *from, pg_wchar *to, int len); +extern int pg_encoding_mb2wchar_with_len(int encoding, + const char *from, pg_wchar *to, int len); extern int pg_char_and_wchar_strcmp(const char *s1, const pg_wchar *s2); extern int pg_wchar_strncmp(const pg_wchar *s1, const pg_wchar *s2, size_t n); extern int pg_char_and_wchar_strncmp(const char *s1, const pg_wchar *s2, size_t n); |