aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/or/config.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/or/config.c b/src/or/config.c
index 3e0e0bfb3..6f78b0b66 100644
--- a/src/or/config.c
+++ b/src/or/config.c
@@ -1044,6 +1044,9 @@ const char *get_data_directory(or_options_t *options) {
}
if (d && strncmp(d,"~/",2)==0) {
char *fn = expand_filename(d);
+ if(!fn) {
+ /* XXX complain and exit(1) here */
+ }
tor_free(options->DataDirectory);
options->DataDirectory = fn;
}