]> git.ipfire.org Git - thirdparty/tor.git/commitdiff
On OOM, also log N circuits remaining
authorNick Mathewson <nickm@torproject.org>
Wed, 12 Feb 2014 18:09:02 +0000 (13:09 -0500)
committerNick Mathewson <nickm@torproject.org>
Wed, 12 Feb 2014 18:09:02 +0000 (13:09 -0500)
src/or/circuitlist.c

index ffb5e0cd0e944fb6e518557b0745e629b72f1aac..45fc95b5613779c9d03bf720a7ecf035aae6f54a 100644 (file)
@@ -1589,9 +1589,11 @@ circuits_handle_oom(size_t current_allocation)
   buf_shrink_freelists(1); /* This is necessary to actually release buffer
                               chunks. */
 
-  log_notice(LD_GENERAL, "Removed "U64_FORMAT" bytes by killing %d circuits.",
+  log_notice(LD_GENERAL, "Removed "U64_FORMAT" bytes by killing %d circuits; "
+             "%d circuits remain alive.",
              U64_PRINTF_ARG(mem_recovered),
-             n_circuits_killed);
+             n_circuits_killed,
+             smartlist_len(circlist) - n_circuits_killed);
 
   smartlist_free(circlist);
 }