Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/zabbix/zabbix.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'src/libs/zbxjson/json.c')
-rw-r--r--src/libs/zbxjson/json.c14
1 files changed, 7 insertions, 7 deletions
diff --git a/src/libs/zbxjson/json.c b/src/libs/zbxjson/json.c
index e819f23e892..539c4d834bc 100644
--- a/src/libs/zbxjson/json.c
+++ b/src/libs/zbxjson/json.c
@@ -841,7 +841,7 @@ static unsigned int zbx_json_decode_character(const char **p, unsigned char *byt
* string copying failed. *
* *
******************************************************************************/
-static const char *zbx_json_copy_string(const char *p, char *out, size_t size)
+const char *json_copy_string(const char *p, char *out, size_t size)
{
char *start = out;
@@ -920,7 +920,7 @@ const char *zbx_json_decodevalue(const char *p, char *string, size_t size, zbx_j
/* only primitive values are decoded */
return NULL;
default:
- if (0 == (len = json_parse_value(p, NULL)))
+ if (0 == (len = json_parse_value(p, NULL, NULL)))
return NULL;
}
@@ -930,7 +930,7 @@ const char *zbx_json_decodevalue(const char *p, char *string, size_t size, zbx_j
switch (type_local)
{
case ZBX_JSON_TYPE_STRING:
- return zbx_json_copy_string(p, string, size);
+ return json_copy_string(p, string, size);
case ZBX_JSON_TYPE_NULL:
if (0 == size)
return NULL;
@@ -954,7 +954,7 @@ const char *zbx_json_decodevalue_dyn(const char *p, char **string, size_t *strin
/* only primitive values are decoded */
return NULL;
default:
- if (0 == (len = json_parse_value(p, NULL)))
+ if (0 == (len = json_parse_value(p, NULL, NULL)))
return NULL;
}
@@ -970,7 +970,7 @@ const char *zbx_json_decodevalue_dyn(const char *p, char **string, size_t *strin
switch (type_local)
{
case ZBX_JSON_TYPE_STRING:
- return zbx_json_copy_string(p, *string, *string_alloc);
+ return json_copy_string(p, *string, *string_alloc);
case ZBX_JSON_TYPE_NULL:
**string = '\0';
return p + len;
@@ -987,7 +987,7 @@ const char *zbx_json_pair_next(const struct zbx_json_parse *jp, const char *p, c
if (ZBX_JSON_TYPE_STRING != __zbx_json_type(p))
return NULL;
- if (NULL == (p = zbx_json_copy_string(p, name, len)))
+ if (NULL == (p = json_copy_string(p, name, len)))
return NULL;
SKIP_WHITESPACE(p);
@@ -1219,7 +1219,7 @@ int zbx_json_open_path(const struct zbx_json_parse *jp, const char *path, struct
object.start = p;
if (NULL == (object.end = __zbx_json_rbracket(p)))
- object.end = p + json_parse_value(p, NULL) - 1;
+ object.end = p + json_parse_value(p, NULL, NULL) - 1;
}
*out = object;