[Qemu-devel] [PATCHv4 0/2] ui/curses: BSD portability fixes

Samuel Thibault posted 2 patches 5 years ago
Test checkpatch passed
Test asan passed
Test docker-clang@ubuntu passed
Test docker-mingw@fedora passed
Patches applied successfully (tree, apply log)
git fetch https://github.com/patchew-project/qemu tags/patchew/20190427183307.12796-1-samuel.thibault@ens-lyon.org
Maintainers: Gerd Hoffmann <kraxel@redhat.com>
ui/curses.c | 194 ++++++++++++++++++++++++++++++++++------------------
1 file changed, 126 insertions(+), 68 deletions(-)
[Qemu-devel] [PATCHv4 0/2] ui/curses: BSD portability fixes
Posted by Samuel Thibault 5 years ago
BSD needs a few fixes for wide character manipulations.

Difference with v1:
- Fix unitialized value in error message

Difference with v2:
- Add cchar_t manipulation fix

Difference with v3:
- use mbrtowc/wcrtomb instead of mbtowc/wctomb
- use MB_LEN_MAX instead of MB_CUR_MAX to avoid using a VLA.

Samuel Thibault (2):
  ui/curses: do not assume wchar_t contains unicode
  ui/curses: manipulate cchar_t with standard curses functions

 ui/curses.c | 194 ++++++++++++++++++++++++++++++++++------------------
 1 file changed, 126 insertions(+), 68 deletions(-)

-- 
2.20.1


Re: [Qemu-devel] [PATCHv4 0/2] ui/curses: BSD portability fixes
Posted by Gerd Hoffmann 5 years ago
On Sat, Apr 27, 2019 at 08:33:05PM +0200, Samuel Thibault wrote:
> BSD needs a few fixes for wide character manipulations.
> 
> Difference with v1:
> - Fix unitialized value in error message
> 
> Difference with v2:
> - Add cchar_t manipulation fix
> 
> Difference with v3:
> - use mbrtowc/wcrtomb instead of mbtowc/wctomb
> - use MB_LEN_MAX instead of MB_CUR_MAX to avoid using a VLA.

Added to ui queue.

thanks,
  Gerd