mirror of
https://gitlab.torproject.org/tpo/core/tor.git
synced 2024-11-30 23:53:32 +01:00
Add an extra flush attempt when closing wedged dir conns, in an attempt to isolate the EPIPE bug
svn:r1848
This commit is contained in:
parent
ef13f70422
commit
3e2f889a29
@ -352,6 +352,11 @@ static void run_connection_housekeeping(int i, time_t now) {
|
|||||||
!conn->marked_for_close &&
|
!conn->marked_for_close &&
|
||||||
conn->timestamp_lastwritten + 5*60 < now) {
|
conn->timestamp_lastwritten + 5*60 < now) {
|
||||||
log_fn(LOG_WARN,"Expiring wedged directory conn (purpose %d)", conn->purpose);
|
log_fn(LOG_WARN,"Expiring wedged directory conn (purpose %d)", conn->purpose);
|
||||||
|
/* XXXX This next check may help isolate where the pesky EPIPE bug
|
||||||
|
* really occurs. */
|
||||||
|
if (connection_wants_to_flush(conn)) {
|
||||||
|
flush_buf(conn->s, conn->outbuf, &conn->outbuf_flushlen);
|
||||||
|
}
|
||||||
connection_mark_for_close(conn,0);
|
connection_mark_for_close(conn,0);
|
||||||
/* XXXX Does this next part make sense, really? */
|
/* XXXX Does this next part make sense, really? */
|
||||||
conn->hold_open_until_flushed = 1; /* give it a last chance */
|
conn->hold_open_until_flushed = 1; /* give it a last chance */
|
||||||
|
Loading…
Reference in New Issue
Block a user