anchor.diff:              send_request(State#client_state{socket = undefined, attempts = Attempts - 1});
           {error, _Reason} ->
               lhttpc_sock:close(Socket, Ssl),
  -            {reply, {error, connection_closed}, State#client_state{socket = undefined,
  -                                                                   request = undefined}}
  +            {reply, {error, connection_closed}, State#client_state{socket = undefined}}
       end.
   
   %%------------------------------------------------------------------------------
  
positive.code:         {error, closed} ->
              lhttpc_sock:close(Socket, ProxyIsSsl),
              {{error, proxy_connection_closed},
               State#client_state{socket = undefined, request = undefined}};
          {error, Reason} ->
              {{error, {proxy_connection_failed, Reason}},
               State#client_state{request = undefined}}
      end.
  
  %%------------------------------------------------------------------------------
  
negative.code: %%------------------------------------------------------------------------------
  %% @private
  %%------------------------------------------------------------------------------
  maybe_close_socket(#client_state{socket = Socket} = State, {1, 1}, ReqHdrs,
  		   RespHdrs) ->
      ClientConnection = case lists:keyfind(<<"connection">>, 1, ReqHdrs) of
  			   false ->
  			       false;
  