diff options
author | Nick Mathewson <nickm@torproject.org> | 2016-05-02 14:02:15 -0400 |
---|---|---|
committer | Nick Mathewson <nickm@torproject.org> | 2016-05-02 14:02:15 -0400 |
commit | 8340becd39920ef6363ab6c7d494cc7abf70c202 (patch) | |
tree | 634a3550090ddeb4e5672b036b626074a1399d5e /src | |
parent | b2083cba9eb842ae7e85063d5751ddddc7302acb (diff) | |
parent | 054d9398531b148d8b41c382da36c83c0381e09e (diff) | |
download | tor-8340becd39920ef6363ab6c7d494cc7abf70c202.tar.gz tor-8340becd39920ef6363ab6c7d494cc7abf70c202.zip |
Merge branch 'maint-0.2.8'
Diffstat (limited to 'src')
-rw-r--r-- | src/or/control.c | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/src/or/control.c b/src/or/control.c index 655b4dd335..e06d7d28a2 100644 --- a/src/or/control.c +++ b/src/or/control.c @@ -2011,6 +2011,11 @@ getinfo_helper_dir(control_connection_t *control_conn, char *filename = get_datadir_fname("cached-consensus"); *answer = read_file_to_str(filename, RFTS_IGNORE_MISSING, NULL); tor_free(filename); + if (!*answer) { /* generate an error */ + *errmsg = "Could not open cached consensus. " + "Make sure FetchUselessDescriptors is set to 1."; + return -1; + } } } else if (!strcmp(question, "network-status")) { /* v1 */ routerlist_t *routerlist = router_get_routerlist(); |