mirror of
https://gitlab.gnome.org/GNOME/glib.git
synced 2025-04-15 12:08:04 +02:00
win32: use wide-char for constants
Use the appropriate type for comparisons and assignment of wide chars. Signed-off-by: Marc-André Lureau <marcandre.lureau@gmail.com> https://bugzilla.gnome.org/show_bug.cgi?id=762202
This commit is contained in:
parent
622748680c
commit
37ebc83f7f
@ -203,8 +203,8 @@ g_win32_error_message (gint error)
|
|||||||
{
|
{
|
||||||
nchars = wcslen (msg);
|
nchars = wcslen (msg);
|
||||||
|
|
||||||
if (nchars >= 2 && msg[nchars-1] == '\n' && msg[nchars-2] == '\r')
|
if (nchars >= 2 && msg[nchars-1] == L'\n' && msg[nchars-2] == L'\r')
|
||||||
msg[nchars-2] = '\0';
|
msg[nchars-2] = L'\0';
|
||||||
|
|
||||||
retval = g_utf16_to_utf8 (msg, -1, NULL, NULL, NULL);
|
retval = g_utf16_to_utf8 (msg, -1, NULL, NULL, NULL);
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user