diff options
author | Nick Mathewson <nickm@torproject.org> | 2007-12-20 06:15:09 +0000 |
---|---|---|
committer | Nick Mathewson <nickm@torproject.org> | 2007-12-20 06:15:09 +0000 |
commit | 2f922937d351d7e25d64dc66d25568b88b16c7a7 (patch) | |
tree | 2096cd209f4919fc8fe89879fc9dc6491e17aa21 /src/or/config.c | |
parent | 6de2b484cf8e236cbf348d6f4c90dc453ae6a4a6 (diff) | |
download | tor-2f922937d351d7e25d64dc66d25568b88b16c7a7.tar tor-2f922937d351d7e25d64dc66d25568b88b16c7a7.tar.gz |
r17274@catbus: nickm | 2007-12-20 01:14:09 -0500
Don't try to create the datadir when we are only verifying the configuration or hashing a password. Resolves bug 540.
svn:r12884
Diffstat (limited to 'src/or/config.c')
-rw-r--r-- | src/or/config.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/or/config.c b/src/or/config.c index a7650637f..83fec4e1b 100644 --- a/src/or/config.c +++ b/src/or/config.c @@ -1004,7 +1004,8 @@ options_act_reversible(or_options_t *old_options, char **msg) } /* Ensure data directory is private; create if possible. */ - if (check_private_dir(options->DataDirectory, CPD_CREATE)<0) { + if (check_private_dir(options->DataDirectory, + running_tor ? CPD_CREATE : CPD_CHECK)<0) { char buf[1024]; int tmp = tor_snprintf(buf, sizeof(buf), "Couldn't access/create private data directory \"%s\"", |