diff options
author | Florian Dold <florian@dold.me> | 2021-07-28 17:34:44 +0200 |
---|---|---|
committer | Florian Dold <florian@dold.me> | 2021-07-28 17:35:15 +0200 |
commit | 7a0caef7a7b1a3fe2949b6a0462125471905540b (patch) | |
tree | c1bcd66710e7aa7cc8a264016609b8a4a9f85ddd /src/include | |
parent | 8593b269709c6c328cad98e5f494e0339def8e62 (diff) | |
download | gnunet-7a0caef7a7b1a3fe2949b6a0462125471905540b.tar.gz gnunet-7a0caef7a7b1a3fe2949b6a0462125471905540b.zip |
diagnostics mode for gnunet-config
Diffstat (limited to 'src/include')
-rw-r--r-- | src/include/gnunet_configuration_lib.h | 23 |
1 files changed, 23 insertions, 0 deletions
diff --git a/src/include/gnunet_configuration_lib.h b/src/include/gnunet_configuration_lib.h index 68ed570a3..7a0dec792 100644 --- a/src/include/gnunet_configuration_lib.h +++ b/src/include/gnunet_configuration_lib.h | |||
@@ -139,6 +139,19 @@ GNUNET_CONFIGURATION_serialize (const struct GNUNET_CONFIGURATION_Handle *cfg, | |||
139 | 139 | ||
140 | 140 | ||
141 | /** | 141 | /** |
142 | * Serializes the given configuration with diagnostics information. | ||
143 | * Diagnostics information will only be available if diagnostics | ||
144 | * have been enabled before parsing. | ||
145 | * | ||
146 | * @param cfg configuration to serialize | ||
147 | * @return the memory block where the serialized configuration is | ||
148 | * present. This memory should be freed by the caller | ||
149 | */ | ||
150 | char * | ||
151 | GNUNET_CONFIGURATION_serialize_diagnostics (const struct | ||
152 | GNUNET_CONFIGURATION_Handle *cfg); | ||
153 | |||
154 | /** | ||
142 | * De-serializes configuration | 155 | * De-serializes configuration |
143 | * | 156 | * |
144 | * @param cfg configuration to update | 157 | * @param cfg configuration to update |
@@ -234,6 +247,16 @@ GNUNET_CONFIGURATION_parse_and_run (const char *filename, | |||
234 | GNUNET_CONFIGURATION_Callback cb, | 247 | GNUNET_CONFIGURATION_Callback cb, |
235 | void *cb_cls); | 248 | void *cb_cls); |
236 | 249 | ||
250 | /** | ||
251 | * Enable extra diagnostics. Will produce more log output | ||
252 | * and allocate more memory. | ||
253 | * | ||
254 | * @param cfg configuration handle | ||
255 | */ | ||
256 | void | ||
257 | GNUNET_CONFIGURATION_enable_diagnostics (struct | ||
258 | GNUNET_CONFIGURATION_Handle *cfg); | ||
259 | |||
237 | 260 | ||
238 | /** | 261 | /** |
239 | * Function to iterate over options. | 262 | * Function to iterate over options. |