Hide options beginning with "___" from GETINFO config/names

This commit is contained in:
meejah 2012-03-19 00:00:10 -06:00 committed by Nick Mathewson
parent 65838f4883
commit f43946829c

View File

@ -7307,6 +7307,9 @@ getinfo_helper_config(control_connection_t *conn,
for (i = 0; _option_vars[i].name; ++i) {
const config_var_t *var = &_option_vars[i];
const char *type;
/* don't tell controller about triple-underscore options */
if (!strncmp(_option_vars[i].name, "___", 3))
continue;
switch (var->type) {
case CONFIG_TYPE_STRING: type = "String"; break;
case CONFIG_TYPE_FILENAME: type = "Filename"; break;