summaryrefslogtreecommitdiff
path: root/include/apr_json.h
diff options
context:
space:
mode:
authorGraham Leggett <minfrin@apache.org>2018-08-30 11:05:52 +0000
committerGraham Leggett <minfrin@apache.org>2018-08-30 11:05:52 +0000
commitde8233919f5be181beb84ec366fdce5be706e280 (patch)
tree8fa245ed7f8ec329835cf7aef91e5cc8aabc1ca1 /include/apr_json.h
parent9bac90373dfdc89fde95aa7a1331de98629aaeed (diff)
downloadapr-de8233919f5be181beb84ec366fdce5be706e280.tar.gz
Teach apr_json_object_get() to support a length, to align with apr_hash_get().
git-svn-id: https://svn.apache.org/repos/asf/apr/apr/trunk@1839658 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'include/apr_json.h')
-rw-r--r--include/apr_json.h5
1 files changed, 4 insertions, 1 deletions
diff --git a/include/apr_json.h b/include/apr_json.h
index 3fc127e23..02e352161 100644
--- a/include/apr_json.h
+++ b/include/apr_json.h
@@ -267,10 +267,13 @@ APR_DECLARE(apr_status_t) apr_json_object_set(apr_json_value_t *obj,
* Look up the value associated with a key in a JSON object.
* @param obj The JSON object.
* @param key Pointer to the key.
+ * @param klen Length of the key, or APR_JSON_VALUE_STRING if NUL
+ * terminated.
* @return Returns NULL if the key is not present.
*/
APR_DECLARE(apr_json_kv_t *)
- apr_json_object_get(apr_json_value_t *obj, const char *key)
+ apr_json_object_get(apr_json_value_t *obj, const char *key,
+ apr_ssize_t klen)
__attribute__((nonnull(1, 2)));
/**