From 7d2cb485116636595250fce4ea4eab16a877479b Mon Sep 17 00:00:00 2001 From: Gregory Maxwell Date: Fri, 16 Jan 2015 05:59:36 -0800 Subject: Restore RPC HTTP keepalives to default. This avoids a regression for issues like #334 where high speed repeated connections eventually run the HTTP client out of sockets because all of theirs end up in time_wait. Maybe the trade-off here is suboptimal, but if both choices will fail then we prefer fewer changes until the root cause is solved. --- src/rpcserver.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/rpcserver.cpp') diff --git a/src/rpcserver.cpp b/src/rpcserver.cpp index 9ebacdbe2e..cb87142902 100644 --- a/src/rpcserver.cpp +++ b/src/rpcserver.cpp @@ -953,7 +953,7 @@ void ServiceConnection(AcceptedConnection *conn) ReadHTTPMessage(conn->stream(), mapHeaders, strRequest, nProto, MAX_SIZE); // HTTP Keep-Alive is false; close connection immediately - if ((mapHeaders["connection"] == "close") || (!GetBoolArg("-rpckeepalive", false))) + if ((mapHeaders["connection"] == "close") || (!GetBoolArg("-rpckeepalive", true))) fRun = false; // Process via JSON-RPC API -- cgit v1.2.3