summaryrefslogtreecommitdiff
path: root/src/or/confparse.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/or/confparse.c')
-rw-r--r--src/or/confparse.c7
1 files changed, 4 insertions, 3 deletions
diff --git a/src/or/confparse.c b/src/or/confparse.c
index 233cc7c77d..8bd4b81cda 100644
--- a/src/or/confparse.c
+++ b/src/or/confparse.c
@@ -192,7 +192,7 @@ config_find_deprecation(const config_format_t *fmt, const char *key)
if (fmt->deprecations == NULL)
return NULL;
- config_deprecation_t *d;
+ const config_deprecation_t *d;
for (d = fmt->deprecations; d->name; ++d) {
if (!strcasecmp(d->name, key)) {
return d->why_deprecated ? d->why_deprecated : "";
@@ -486,10 +486,11 @@ config_mark_lists_fragile(const config_format_t *fmt, void *options)
void
warn_deprecated_option(const char *what, const char *why)
{
+ const char *space = (why && strlen(why)) ? " " : "";
log_warn(LD_CONFIG, "The %s option is deprecated, and will most likely "
- "be removed in a future version of Tor.%s (If you think this is "
+ "be removed in a future version of Tor.%s%s (If you think this is "
"a mistake, please let us know!)",
- what, why);
+ what, space, why);
}
/** If <b>c</b> is a syntactically valid configuration line, update