anchor.diff:                    end
             end,
       ?Debug("Request data = ~s~n", [binary_to_list(un_partial(Bin))]),
  -    ARG = make_arg(CliSock, Head, Req, Bin),
  +    ARG = make_arg(CliSock, IPPort, Head, Req, Bin),
       handle_request(CliSock, ARG, size(un_partial(Bin))).
   
   
  -'MKCOL'(CliSock, Req, Head) ->
  -    no_body_method(CliSock, Req, Head).
  -
  -no_body_method(CliSock, Req, Head) ->
  +'MKCOL'(CliSock, IPPort, Req, Head) ->
  +    no_body_method(CliSock, IPPort, Req, Head).
  +
  +no_body_method(CliSock, IPPort, Req, Head) ->
       SC=get(sc),
       ok = yaws:setopts(CliSock, [{packet, raw}, binary], yaws:is_ssl(SC)),
       flush(CliSock, Head#headers.content_length),
  -    ARG = make_arg(CliSock, Head, Req, undefined),
  +    ARG = make_arg(CliSock, IPPort, Head, Req, undefined),
       handle_request(CliSock, ARG, 0).
   
   
  -make_arg(CliSock, Head, Req, Bin) ->
  +make_arg(CliSock, IPPort, Head, Req, Bin) ->
       SC = get(sc),
  -    IP = if
  -             is_port(CliSock) ->
  -                 case inet:peername(CliSock) of
  -                     {ok, IpPort} ->
  -                         IpPort;
  -                     _ ->
  -                         {unknown, unknown}
  -                 end;
  -             true ->
  -                 case ssl:peername(CliSock) of
  -                     {ok, IpPort} ->
  -                         IpPort;
  -                     _ ->
  -                         {unknown, unknown}
  -                 end
  -         end,
       ARG = #arg{clisock = CliSock,
  -               client_ip_port = IP,
  +               client_ip_port = IPPort,
                  headers = Head,
                  req = Req,
                  opaque = SC#sconf.opaque,
  
positive.code:     end.
  
  maybe_access_log(Ip, Req, H) ->
      SC=get(sc),
      case ?sc_has_access_log(SC) of
          true ->
              Time = timer:now_diff(now(), get(request_start_time)),
              yaws_log:accesslog(SC, Ip, Req, H, get(outh), Time);
          false ->
              ignore
      end.
  
negative.code:          deliver_dyn_part/8, finish_up_dyn_file/2, gserv_loop/4
          ]).
  
  -export(['GET'/4,
           'POST'/4,
           'HEAD'/4,
           'TRACE'/4,
           'OPTIONS'/4,
           'PUT'/4,
           'DELETE'/4,
           'PATCH'/4]).
  
  -import(lists, [member/2, foreach/2, map/2,
                  flatten/1, flatmap/2, reverse/1]).
  