mirror of
https://github.com/PowerShell/Win32-OpenSSH.git
synced 2025-07-21 13:04:57 +02:00
Fix progress meter utf8
This commit is contained in:
parent
58a582815f
commit
0b55122f42
@ -237,7 +237,14 @@ refresh_progress_meter(void)
|
||||
strlcat(buf, " ", win_size);
|
||||
}
|
||||
|
||||
#ifdef WINDOWS
|
||||
wchar_t* wtmp = utf8_to_utf16(buf);
|
||||
WriteConsoleW(GetStdHandle(STD_OUTPUT_HANDLE), wtmp, wcslen(wtmp), 0, 0);
|
||||
WriteConsoleW(GetStdHandle(STD_OUTPUT_HANDLE), L"\n", 1, 0, 0);
|
||||
free(wtmp);
|
||||
#else
|
||||
atomicio(vwrite, STDOUT_FILENO, buf, win_size - 1);
|
||||
#endif
|
||||
last_update = now;
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user