aboutsummaryrefslogtreecommitdiff
path: root/src/common/json_util.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/common/json_util.h')
-rw-r--r--src/common/json_util.h4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/common/json_util.h b/src/common/json_util.h
index 6f8b4c18f..45046a4fb 100644
--- a/src/common/json_util.h
+++ b/src/common/json_util.h
@@ -28,8 +28,8 @@
#pragma once
-#define GET_FIELD_FROM_JSON_RETURN_ON_ERROR(json, name, type, jtype, mandatory) \
- type field_##name; \
+#define GET_FIELD_FROM_JSON_RETURN_ON_ERROR(json, name, type, jtype, mandatory, def) \
+ type field_##name = def; \
bool field_##name##_found = false; \
(void)field_##name##_found; \
do if (json.HasMember(#name)) \