summaryrefslogtreecommitdiff
path: root/src/app/config/confparse.c
diff options
context:
space:
mode:
authorNick Mathewson <nickm@torproject.org>2019-08-27 11:12:34 -0400
committerNick Mathewson <nickm@torproject.org>2019-08-28 09:42:17 -0400
commit8db3859cc6f394927ca66bfc19c1227408fb7874 (patch)
treea39fc0e05591f1eef6a02820f36365a378c02de6 /src/app/config/confparse.c
parentd9fe9f5edef53c53e2e2337f8af0d88e42e47d4a (diff)
downloadtor-8db3859cc6f394927ca66bfc19c1227408fb7874.tar.gz
tor-8db3859cc6f394927ca66bfc19c1227408fb7874.zip
Simple tests for nested configuration formats
One test makes sure that the toplevel magic numbers are distinct. One test makes sure that we can parse a configuration object with two sub-objects.
Diffstat (limited to 'src/app/config/confparse.c')
-rw-r--r--src/app/config/confparse.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/app/config/confparse.c b/src/app/config/confparse.c
index 5c994c0a6a..71ba39ef52 100644
--- a/src/app/config/confparse.c
+++ b/src/app/config/confparse.c
@@ -234,7 +234,7 @@ config_mgr_get_suite_ptr(const config_mgr_t *mgr, void *toplevel)
* to configuration objects for other modules. This function gets
* the sub-object for a particular modules.
*/
-static void *
+STATIC void *
config_mgr_get_obj_mutable(const config_mgr_t *mgr, void *toplevel, int idx)
{
tor_assert(mgr);
@@ -253,7 +253,7 @@ config_mgr_get_obj_mutable(const config_mgr_t *mgr, void *toplevel, int idx)
}
/** As config_mgr_get_obj_mutable(), but return a const pointer. */
-static const void *
+STATIC const void *
config_mgr_get_obj(const config_mgr_t *mgr, const void *toplevel, int idx)
{
return config_mgr_get_obj_mutable(mgr, (void*)toplevel, idx);