summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorTom Lane <tgl@sss.pgh.pa.us>2010-07-07 15:13:21 +0000
committerTom Lane <tgl@sss.pgh.pa.us>2010-07-07 15:13:21 +0000
commit5b1b3ef742723009e5f9b7a009aa8eda3578305a (patch)
treedae9fde092f8586d44176af4b4e2c80cb0a3acf2 /src
parente3243488b06aa17a4ce14a5c4e3234284a3789b8 (diff)
downloadpostgresql-5b1b3ef742723009e5f9b7a009aa8eda3578305a.tar.gz
Adjust mbutils.c so it won't get broken by future pgindent runs.
To do that, replace L'\0' by (WCHAR) 0. Perhaps someday we should teach pgindent about wide-character literals, but so long as this is the only use-case in the entire Postgres sources, a workaround seems easier.
Diffstat (limited to 'src')
-rw-r--r--src/backend/utils/mb/mbutils.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/backend/utils/mb/mbutils.c b/src/backend/utils/mb/mbutils.c
index da93ad0535..ddaf881ce0 100644
--- a/src/backend/utils/mb/mbutils.c
+++ b/src/backend/utils/mb/mbutils.c
@@ -4,7 +4,7 @@
*
* Tatsuo Ishii
*
- * $PostgreSQL: pgsql/src/backend/utils/mb/mbutils.c,v 1.97 2010/07/06 21:09:00 tgl Exp $
+ * $PostgreSQL: pgsql/src/backend/utils/mb/mbutils.c,v 1.98 2010/07/07 15:13:21 tgl Exp $
*/
#include "postgres.h"
@@ -1016,7 +1016,7 @@ pgwin32_toUTF16(const char *str, int len, int *utf16len)
{
utf16 = (WCHAR *) palloc(sizeof(WCHAR) * (len + 1));
dstlen = MultiByteToWideChar(codepage, 0, str, len, utf16, len);
- utf16[dstlen] = L'\0';
+ utf16[dstlen] = (WCHAR) 0;
}
else
{
@@ -1029,7 +1029,7 @@ pgwin32_toUTF16(const char *str, int len, int *utf16len)
utf16 = (WCHAR *) palloc(sizeof(WCHAR) * (len + 1));
dstlen = MultiByteToWideChar(CP_UTF8, 0, utf8, len, utf16, len);
- utf16[dstlen] = L'\0';
+ utf16[dstlen] = (WCHAR) 0;
if (utf8 != str)
pfree(utf8);