summaryrefslogtreecommitdiff
path: root/src/or/relay.c
diff options
context:
space:
mode:
authorNick Mathewson <nickm@torproject.org>2014-08-19 10:59:15 -0400
committerNick Mathewson <nickm@torproject.org>2014-08-24 13:04:27 -0400
commit8e55cafd672353979e7628d5dad9e12429b401dd (patch)
tree5c21280017363ee9b31356013d7ab5961bfa4f04 /src/or/relay.c
parentec59167cae1f5b3057ed722857d78ec78239e991 (diff)
downloadtor-8e55cafd672353979e7628d5dad9e12429b401dd.tar.gz
tor-8e55cafd672353979e7628d5dad9e12429b401dd.zip
Count zlib buffer memory towards OOM totals.
Part of 11792. (Uses the zlib-endorsed formula for memory needs for inflate/deflate from "zconf.h".)
Diffstat (limited to 'src/or/relay.c')
-rw-r--r--src/or/relay.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/src/or/relay.c b/src/or/relay.c
index f42602d412..7d7ef7a835 100644
--- a/src/or/relay.c
+++ b/src/or/relay.c
@@ -2433,6 +2433,7 @@ cell_queues_check_size(void)
{
size_t alloc = cell_queues_get_total_allocation();
alloc += buf_get_total_allocation();
+ alloc += tor_zlib_get_total_allocation();
if (alloc >= get_options()->MaxMemInQueues) {
circuits_handle_oom(alloc);
return 1;