GNUnet 0.21.1
gnunet-config-diff.c
Go to the documentation of this file.
1
2#include "platform.h"
3#include <gnunet_util_lib.h>
4
5int
6main (int argc, char **argv)
7{
10
11 if (argc != 3)
12 {
13 fprintf (stderr, "Invoke using `%s DEFAULTS-IN DIFFS'\n", argv[0]);
14 return 1;
15 }
18 if ((GNUNET_OK != GNUNET_CONFIGURATION_load (i1, argv[1])) ||
19 (GNUNET_OK != GNUNET_CONFIGURATION_load (i2, argv[2])))
20 return 1;
21 if (GNUNET_OK != GNUNET_CONFIGURATION_write_diffs (i1, i2, argv[2]))
22 return 2;
23 return 0;
24}
int main(int argc, char **argv)
struct GNUNET_CONFIGURATION_Handle * GNUNET_CONFIGURATION_create(void)
Create a new configuration object.
enum GNUNET_GenericReturnValue GNUNET_CONFIGURATION_load(struct GNUNET_CONFIGURATION_Handle *cfg, const char *filename)
Load configuration.
enum GNUNET_GenericReturnValue GNUNET_CONFIGURATION_write_diffs(const struct GNUNET_CONFIGURATION_Handle *cfg_default, const struct GNUNET_CONFIGURATION_Handle *cfg_new, const char *filename)
Write only configuration entries that have been changed to configuration file.
@ GNUNET_OK