From: Robert Ransom Date: Thu, 1 Dec 2011 23:26:45 +0000 (-0800) Subject: Don't segfault when checking whether a not-yet-used intro point should expire X-Git-Tag: tor-0.2.3.9-alpha~21 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=5ffa7102c00385445d3855bbc481668edf62d139;p=thirdparty%2Ftor.git Don't segfault when checking whether a not-yet-used intro point should expire Found by katmagic. Bugfix on the #3460 branch, not yet in any release. --- diff --git a/src/or/rendservice.c b/src/or/rendservice.c index a360d5ce58..177f3bf23c 100644 --- a/src/or/rendservice.c +++ b/src/or/rendservice.c @@ -1957,7 +1957,8 @@ intro_point_should_expire_now(rend_intro_point_t *intro, return 1; } - if (digestmap_size(intro->accepted_intro_rsa_parts) >= + if (intro->accepted_intro_rsa_parts != NULL && + digestmap_size(intro->accepted_intro_rsa_parts) >= INTRO_POINT_LIFETIME_INTRODUCTIONS) { /* This intro point has been used too many times. Expire it now. */ return 1;