summaryrefslogtreecommitdiff
path: root/src/include/mb
diff options
context:
space:
mode:
authorMagnus Hagander2009-10-17 00:24:51 +0000
committerMagnus Hagander2009-10-17 00:24:51 +0000
commit748771379b9463ee7454630b3cb3f3087b3157cb (patch)
treee5b2b785157c95b41748f4f31bc82bc4772c32f4 /src/include/mb
parent76c09dbe8d01a6932de321b97307b488b0f47d25 (diff)
Write to the Windows eventlog in UTF16, converting the message encoding
as necessary. Itagaki Takahiro with some changes from me
Diffstat (limited to 'src/include/mb')
-rw-r--r--src/include/mb/pg_wchar.h10
1 files changed, 9 insertions, 1 deletions
diff --git a/src/include/mb/pg_wchar.h b/src/include/mb/pg_wchar.h
index e9faff00130..353d612f758 100644
--- a/src/include/mb/pg_wchar.h
+++ b/src/include/mb/pg_wchar.h
@@ -6,7 +6,7 @@
* Portions Copyright (c) 1996-2009, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
- * $PostgreSQL: pgsql/src/include/mb/pg_wchar.h,v 1.91 2009/06/11 14:49:11 momjian Exp $
+ * $PostgreSQL: pgsql/src/include/mb/pg_wchar.h,v 1.92 2009/10/17 00:24:51 mha Exp $
*
* NOTES
* This is used both by the backend and by libpq, but should not be
@@ -257,6 +257,9 @@ typedef struct pg_enc2name
{
char *name;
pg_enc encoding;
+#ifdef WIN32
+ unsigned codepage; /* codepage for WIN32 */
+#endif
} pg_enc2name;
extern pg_enc2name pg_enc2name_tbl[];
@@ -402,6 +405,7 @@ extern const char *pg_get_client_encoding_name(void);
extern void SetDatabaseEncoding(int encoding);
extern int GetDatabaseEncoding(void);
extern const char *GetDatabaseEncodingName(void);
+extern int GetPlatformEncoding(void);
extern void pg_bind_textdomain_codeset(const char *domainname);
extern int pg_valid_client_encoding(const char *name);
@@ -458,4 +462,8 @@ extern void mic2latin_with_table(const unsigned char *mic, unsigned char *p,
extern bool pg_utf8_islegal(const unsigned char *source, int length);
+#ifdef WIN32
+extern WCHAR *pgwin32_toUTF16(const char *str, int len, int *utf16len);
+#endif
+
#endif /* PG_WCHAR_H */