aboutsummaryrefslogtreecommitdiff
path: root/src/rpcserver.cpp
diff options
context:
space:
mode:
authorGregory Maxwell <greg@xiph.org>2015-01-16 05:59:36 -0800
committerGregory Maxwell <greg@xiph.org>2015-01-16 05:59:36 -0800
commit7d2cb485116636595250fce4ea4eab16a877479b (patch)
treef11efc3600433245b3755dc3e874face70f8238c /src/rpcserver.cpp
parent9fe53a85e0e50ca82e369b7d29485a0a6f0f8dbf (diff)
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.
Diffstat (limited to 'src/rpcserver.cpp')
-rw-r--r--src/rpcserver.cpp2
1 files changed, 1 insertions, 1 deletions
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