anchor.diff:                         encode_headers(Headers0), <<"\r\n">>],
       case gen_tcp:send(Socket, ResponseHeaders) of
           ok ->
  -            case send_file(Socket, Filename, Range) of
  +            case send_file(Socket, Filename, Size, Range) of
                   {ok, _BytesSent} -> ok;
                   {error, closed} ->
                       Mod:handle_event(client_closed, [before_response], Args),
  
positive.code:             ok
      end.
  
  send_file(Socket, Filename, {Offset, Bytes}) ->
      case file:open(Filename, [read, raw, binary]) of
          {ok, Fd} ->
              Res = file:sendfile(Fd, Socket, Offset, Bytes, []),
  
negative.code:     Headers0 = set_range_and_length(Range, Size, Headers),
      %% Rewrite status code when a (in)valid range is present.
      Code0 = case Range of
                  undefined when Size =:= 0, Code =:= 200 -> 204;
                  undefined -> Code;
                  {_,_}     -> 206;
                  invalid   -> 416
  