diff options
author | Nick Mathewson <nickm@torproject.org> | 2013-09-05 09:59:07 -0400 |
---|---|---|
committer | Nick Mathewson <nickm@torproject.org> | 2013-09-05 09:59:07 -0400 |
commit | c7113e702b7e0ad1f33eb72cc8fffc5f26d0ae64 (patch) | |
tree | 59bef7eaec68bd83d380c0e34d7c2140ab2999c7 /src/or/microdesc.c | |
parent | 86907ea4db5067d1fbf56275457a919d6789ba95 (diff) | |
parent | 264aa271a734767a13065bc6e0d15c4d8c602005 (diff) | |
download | tor-c7113e702b7e0ad1f33eb72cc8fffc5f26d0ae64.tar.gz tor-c7113e702b7e0ad1f33eb72cc8fffc5f26d0ae64.zip |
Merge remote-tracking branch 'public/bug9645'
Diffstat (limited to 'src/or/microdesc.c')
-rw-r--r-- | src/or/microdesc.c | 9 |
1 files changed, 4 insertions, 5 deletions
diff --git a/src/or/microdesc.c b/src/or/microdesc.c index 8c763c6729..f6dd6b611b 100644 --- a/src/or/microdesc.c +++ b/src/or/microdesc.c @@ -213,7 +213,6 @@ microdescs_add_list_to_cache(microdesc_cache_t *cache, if (fd < 0) { log_warn(LD_DIR, "Couldn't append to journal in %s: %s", cache->journal_fname, strerror(errno)); - return NULL; } } @@ -238,11 +237,11 @@ microdescs_add_list_to_cache(microdesc_cache_t *cache, if (size < 0) { /* we already warned in dump_microdescriptor */ abort_writing_to_file(open_file); - smartlist_clear(added); - return added; + fd = -1; + } else { + md->saved_location = SAVED_IN_JOURNAL; + cache->journal_len += size; } - md->saved_location = SAVED_IN_JOURNAL; - cache->journal_len += size; } else { md->saved_location = where; } |