Re: [Openvpn-devel] [PATCH v2] Format Windows error message in Unicode

2023-04-18 Thread Frank Lichtenheld
On Tue, Apr 18, 2023 at 10:14:46AM -0400, selva.n...@gmail.com wrote: > From: Selva Nair > > - We assume that all text passed to the management interface > and written to log file are in Unicode (UTF-8). This is broken by > the use of the ANSI version of FormatMessage() for Windows error >

[Openvpn-devel] [PATCH v2] Format Windows error message in Unicode

2023-04-18 Thread selva . nair
From: Selva Nair - We assume that all text passed to the management interface and written to log file are in Unicode (UTF-8). This is broken by the use of the ANSI version of FormatMessage() for Windows error messages. Fix by using FormatMessageW() and converting the UTF-16 result to UTF-