diff options
Diffstat (limited to 'src/lib/conf')
-rw-r--r-- | src/lib/conf/confmacros.h | 4 | ||||
-rw-r--r-- | src/lib/conf/conftypes.h | 6 |
2 files changed, 9 insertions, 1 deletions
diff --git a/src/lib/conf/confmacros.h b/src/lib/conf/confmacros.h index ff284e681d..aa89965e69 100644 --- a/src/lib/conf/confmacros.h +++ b/src/lib/conf/confmacros.h @@ -60,6 +60,8 @@ } #define CONFIG_VAR_OBSOLETE(varname) \ - { .member = { .name = varname, .type = CONFIG_TYPE_OBSOLETE } } + { .member = { .name = varname, .type = CONFIG_TYPE_OBSOLETE }, \ + .flags = CVFLAG_OBSOLETE \ + } #endif /* !defined(TOR_LIB_CONF_CONFMACROS_H) */ diff --git a/src/lib/conf/conftypes.h b/src/lib/conf/conftypes.h index 028a889917..6a44fb92ed 100644 --- a/src/lib/conf/conftypes.h +++ b/src/lib/conf/conftypes.h @@ -105,6 +105,12 @@ typedef struct struct_magic_decl_t { int magic_offset; } struct_magic_decl_t; +/** + * Flag to indicate that an option is obsolete. Any attempt to set or + * fetch this option should produce a warning. + **/ +#define CVFLAG_OBSOLETE (1u<<0) + /** A variable allowed in the configuration file or on the command line. */ typedef struct config_var_t { struct_member_t member; /** A struct member corresponding to this |