From 470c0db2b3a592a7fe47b17818d4d50ed79360b3 Mon Sep 17 00:00:00 2001 From: Ken Takata Date: Thu, 4 Jul 2024 19:35:48 +0200 Subject: patch 9.1.0530: xxd: MSVC warning about non-ASCII character Problem: xxd: MSVC warning about non-ASCII character Solution: Specify source-charset:utf-8 in Makefile (Ken Takata) xxd.c has non-ASCII-character comments. This causes the following warning on MSVC: ``` warning C4819: The file contains a character that cannot be represented in the current code page (932). Save the file in Unicode format to prevent data loss. ``` Add the `/source-charset:utf-8` option to avoid this. closes: #15119 Signed-off-by: Ken Takata Signed-off-by: Christian Brabandt --- src/version.c | 2 ++ src/xxd/Make_mvc.mak | 2 +- 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/src/version.c b/src/version.c index b7812fa009..159fe3b814 100644 --- a/src/version.c +++ b/src/version.c @@ -704,6 +704,8 @@ static char *(features[]) = static int included_patches[] = { /* Add new patch number below this line */ +/**/ + 530, /**/ 529, /**/ diff --git a/src/xxd/Make_mvc.mak b/src/xxd/Make_mvc.mak index 0133d73115..2361ab3d54 100644 --- a/src/xxd/Make_mvc.mak +++ b/src/xxd/Make_mvc.mak @@ -9,7 +9,7 @@ SUBSYSTEM = $(SUBSYSTEM),$(SUBSYSTEM_VER) xxd: xxd.exe xxd.exe: xxd.c - cl /nologo -DWIN32 xxd.c -link -subsystem:$(SUBSYSTEM) + cl /nologo /source-charset:utf-8 -DWIN32 xxd.c -link -subsystem:$(SUBSYSTEM) # This was for an older compiler # cl /nologo -DWIN32 xxd.c /link setargv.obj -- cgit v1.2.3