aboutsummaryrefslogtreecommitdiff
path: root/src/nvim/os/env.c
diff options
context:
space:
mode:
authorJustin M. Keyes <justinkz@gmail.com>2019-08-15 09:32:18 +0200
committerGitHub <noreply@github.com>2019-08-15 09:32:18 +0200
commit6261d2658fdff93a732b02d8fd6e386245968f2d (patch)
tree3dd5de174ff4b0b555a49cff30937a2304b71857 /src/nvim/os/env.c
parenteb9f3308bc329c212009820817d35c6ab7a88117 (diff)
parent975be7e5dcf6a2ee59a6fc236e75b434b6ce4423 (diff)
downloadrneovim-6261d2658fdff93a732b02d8fd6e386245968f2d.tar.gz
rneovim-6261d2658fdff93a732b02d8fd6e386245968f2d.tar.bz2
rneovim-6261d2658fdff93a732b02d8fd6e386245968f2d.zip
Merge #10761 from justinmk/win-utf-libuv-align
utf8_to_utf16, utf16_to_utf8: align with libuv
Diffstat (limited to 'src/nvim/os/env.c')
-rw-r--r--src/nvim/os/env.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/nvim/os/env.c b/src/nvim/os/env.c
index 62457e155c..669475fa72 100644
--- a/src/nvim/os/env.c
+++ b/src/nvim/os/env.c
@@ -178,7 +178,7 @@ char *os_getenvname_at_index(size_t index)
for (wchar_t *it = env; *it != L'\0' || *(it + 1) != L'\0'; it++) {
if (index == current_index) {
char *utf8_str;
- int conversion_result = utf16_to_utf8(it, &utf8_str);
+ int conversion_result = utf16_to_utf8(it, -1, &utf8_str);
if (conversion_result != 0) {
EMSG2("utf16_to_utf8 failed: %d", conversion_result);
break;
@@ -258,7 +258,7 @@ void os_get_hostname(char *hostname, size_t size)
host_utf16[host_wsize] = '\0';
char *host_utf8;
- int conversion_result = utf16_to_utf8(host_utf16, &host_utf8);
+ int conversion_result = utf16_to_utf8(host_utf16, -1, &host_utf8);
if (conversion_result != 0) {
EMSG2("utf16_to_utf8 failed: %d", conversion_result);
return;