Merge remote-tracking branch 'linus/empty_desc_stats'

This commit is contained in:
Nick Mathewson 2012-03-30 10:06:21 -04:00
commit 545cb5f34e
2 changed files with 6 additions and 0 deletions

4
changes/bug5508 Normal file
View File

@ -0,0 +1,4 @@
o Minor bugfixes:
- Fix a bug where a bridge authority crashes (on a failed assert)
if it has seen no directory requests when it's time to write
statistics to disk.

View File

@ -2657,6 +2657,8 @@ rep_hist_format_desc_stats(time_t now)
return NULL;
size = digestmap_size(served_descs);
if (size == 0)
return NULL;
vals = tor_malloc(size * sizeof(int));
for (iter = digestmap_iter_init(served_descs); !digestmap_iter_done(iter);