Return-Path: X-Original-To: apmail-couchdb-commits-archive@www.apache.org Delivered-To: apmail-couchdb-commits-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 830741018F for ; Wed, 12 Feb 2014 06:24:43 +0000 (UTC) Received: (qmail 4563 invoked by uid 500); 12 Feb 2014 06:21:38 -0000 Delivered-To: apmail-couchdb-commits-archive@couchdb.apache.org Received: (qmail 4186 invoked by uid 500); 12 Feb 2014 06:21:24 -0000 Mailing-List: contact commits-help@couchdb.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@couchdb.apache.org Delivered-To: mailing list commits@couchdb.apache.org Received: (qmail 3169 invoked by uid 99); 12 Feb 2014 06:20:54 -0000 Received: from tyr.zones.apache.org (HELO tyr.zones.apache.org) (140.211.11.114) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 12 Feb 2014 06:20:54 +0000 Received: by tyr.zones.apache.org (Postfix, from userid 65534) id 39CA055484; Wed, 12 Feb 2014 06:20:53 +0000 (UTC) Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit From: davisp@apache.org To: commits@couchdb.apache.org Date: Wed, 12 Feb 2014 06:21:16 -0000 Message-Id: In-Reply-To: <9e360a991c2f4811996c0b3e7448668a@git.apache.org> References: <9e360a991c2f4811996c0b3e7448668a@git.apache.org> X-Mailer: ASF-Git Admin Mailer Subject: [27/33] ibrowse commit: updated refs/heads/import-master to 1167b0e Applied 2 more ibrowse fixes already submitted upstream https://github.com/cmullaparthi/ibrowse/pull/24 https://github.com/cmullaparthi/ibrowse/pull/25 git-svn-id: https://svn.apache.org/repos/asf/couchdb/trunk@1056395 13f79535-47bb-0310-9956-ffa450edef68 Project: http://git-wip-us.apache.org/repos/asf/couchdb-ibrowse/repo Commit: http://git-wip-us.apache.org/repos/asf/couchdb-ibrowse/commit/cb08a0db Tree: http://git-wip-us.apache.org/repos/asf/couchdb-ibrowse/tree/cb08a0db Diff: http://git-wip-us.apache.org/repos/asf/couchdb-ibrowse/diff/cb08a0db Branch: refs/heads/import-master Commit: cb08a0db501d5478f305b4916d49da77a15e2a71 Parents: 99da0af Author: Filipe David Borba Manana Authored: Fri Jan 7 17:15:24 2011 +0000 Committer: Filipe David Borba Manana Committed: Fri Jan 7 17:15:24 2011 +0000 ---------------------------------------------------------------------- ibrowse_http_client.erl | 13 +++++++++---- 1 file changed, 9 insertions(+), 4 deletions(-) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/couchdb-ibrowse/blob/cb08a0db/ibrowse_http_client.erl ---------------------------------------------------------------------- diff --git a/ibrowse_http_client.erl b/ibrowse_http_client.erl index ea75948..5dce321 100644 --- a/ibrowse_http_client.erl +++ b/ibrowse_http_client.erl @@ -287,10 +287,14 @@ handle_sock_data(Data, #state{status = get_header}=State) -> {error, _Reason} -> shutting_down(State), {stop, normal, State}; - State_1 -> - active_once(State_1), - State_2 = set_inac_timer(State_1), - {noreply, State_2} + #state{socket = Socket, status = Status, cur_req = CurReq} = State_1 -> + case {Status, CurReq} of + {get_header, #request{caller_controls_socket = true}} -> + do_setopts(Socket, [{active, once}], State_1); + _ -> + active_once(State_1) + end, + {noreply, set_inac_timer(State_1)} end; handle_sock_data(Data, #state{status = get_body, @@ -683,6 +687,7 @@ send_req_1(From, Headers, Method, Body, Options, Timeout, #state{status = Status, socket = Socket} = State) -> + cancel_timer(State#state.inactivity_timer_ref, {eat_message, timeout}), ReqId = make_req_id(), Resp_format = get_value(response_format, Options, list), Caller_socket_options = get_value(socket_options, Options, []),