diff options
author | Roger Dingledine <arma@torproject.org> | 2004-11-06 05:18:11 +0000 |
---|---|---|
committer | Roger Dingledine <arma@torproject.org> | 2004-11-06 05:18:11 +0000 |
commit | 6c61ed4fb5d33a8c51ff342165a26ac70765dd26 (patch) | |
tree | 6a767b637d976bf392a275e99386798bbf094e74 /src/or/routerparse.c | |
parent | f490e5cdb6a60779ddadfba3dd022ba904c00b43 (diff) | |
download | tor-6c61ed4fb5d33a8c51ff342165a26ac70765dd26.tar.gz tor-6c61ed4fb5d33a8c51ff342165a26ac70765dd26.zip |
Make options no longer a global variable.
Now we can try setting an option but back out if it fails to parse, or
if it's disallowed (e.g. changing RunAsDaemon from 1 to 0).
Use parse_line_from_str rather than parse_line_from_file.
svn:r2692
Diffstat (limited to 'src/or/routerparse.c')
-rw-r--r-- | src/or/routerparse.c | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/src/or/routerparse.c b/src/or/routerparse.c index eb02167660..2b99c72a74 100644 --- a/src/or/routerparse.c +++ b/src/or/routerparse.c @@ -12,8 +12,6 @@ /****************************************************************************/ -extern or_options_t options; /* command-line and config-file options */ - /** Enumeration of possible token types. The ones starting with K_ * correspond to directory 'keywords'. _UNRECOGNIZED is for an * unrecognized keyword; _ERR is an error in the tokenizing process, @@ -351,7 +349,7 @@ router_parse_routerlist_from_directory(const char *str, /* Now that we know the signature is okay, check the version. */ if (check_version) - check_software_version_against_directory(str, options.IgnoreVersion); + check_software_version_against_directory(str, get_options()->IgnoreVersion); /* Now try to parse the first part of the directory. */ if ((end = strstr(str,"\nrouter "))) { |