Merge remote-tracking branch 'public/bug9731'

This commit is contained in:
Nick Mathewson 2013-10-31 14:09:18 -04:00
commit 702c0502cf
2 changed files with 9 additions and 0 deletions

3
changes/bug9731 Normal file
View File

@ -0,0 +1,3 @@
o Major bugfixes:
- Do not apply connection_consider_empty_read/write_buckets to
non-rate-limited connections.

View File

@ -2696,6 +2696,9 @@ connection_consider_empty_read_buckets(connection_t *conn)
} else
return; /* all good, no need to stop it */
if (!connection_is_rate_limited(conn))
return; /* Always okay. */
LOG_FN_CONN(conn, (LOG_DEBUG, LD_NET, "%s", reason));
conn->read_blocked_on_bw = 1;
connection_stop_reading(conn);
@ -2720,6 +2723,9 @@ connection_consider_empty_write_buckets(connection_t *conn)
} else
return; /* all good, no need to stop it */
if (!connection_is_rate_limited(conn))
return; /* Always okay. */
LOG_FN_CONN(conn, (LOG_DEBUG, LD_NET, "%s", reason));
conn->write_blocked_on_bw = 1;
connection_stop_writing(conn);