mirror of
https://github.com/microsoft/vcpkg.git
synced 2024-12-21 19:07:50 +08:00
29 lines
830 B
Diff
29 lines
830 B
Diff
diff --git a/CMakeLists.txt b/CMakeLists.txt
|
|
index eda6a72..386966f 100644
|
|
--- a/CMakeLists.txt
|
|
+++ b/CMakeLists.txt
|
|
@@ -58,6 +58,10 @@ elseif(UNIX)
|
|
set(CMAKE_EXE_LINKER_FLAGS "${CMAKE_EXE_LINKER_FLAGS} -Wl,--build-id")
|
|
endif()
|
|
|
|
+if (MSVC)
|
|
+ add_compile_options(/wd4146 -D_CRT_SECURE_NO_WARNINGS)
|
|
+endif()
|
|
+
|
|
enable_testing()
|
|
|
|
add_library(port
|
|
diff --git a/upb/json_decode.c b/upb/json_decode.c
|
|
index 953d238..5185ffd 100644
|
|
--- a/upb/json_decode.c
|
|
+++ b/upb/json_decode.c
|
|
@@ -1138,7 +1138,7 @@ static void jsondec_struct(jsondec *d, upb_msg *msg, const upb_msgdef *m) {
|
|
static void jsondec_wellknownvalue(jsondec *d, upb_msg *msg,
|
|
const upb_msgdef *m) {
|
|
upb_msgval val;
|
|
- const upb_fielddef *f;
|
|
+ const upb_fielddef *f = NULL;
|
|
upb_msg *submsg;
|
|
|
|
switch (jsondec_peek(d)) {
|