anchor.diff:  log_close({?MODULE, Name, FD}) ->
       webmachine_util:to_console("~p: closing log file: ~p~n", [?MODULE, Name]),
       file:close(FD).
  +
  +do_log(Msg, State) ->
  +    NewState = maybe_rotate(State, os:timestamp()),
  +    log_write(NewState#state.handle, Msg),
  +    NewState.
   
   maybe_rotate(State, Time) ->
       ThisHour = datehour(Time),
  
positive.code: -export([start_link/1]).
  -export([init/1, handle_call/3, handle_cast/2, handle_info/2,
           terminate/2, code_change/3]).
  -export([log_access/1, refresh/0, get_metadata/2]).
  
  -include_lib("wm_reqdata.hrl").
  -include_lib("webmachine_logger.hrl").
  
  -record(state, {hourstamp, filename, handle}).
  
  alog_path(BaseDir) ->
      filename:join(BaseDir, "access.log").
  
  start_link(BaseDir) ->
      gen_server:start_link({local, ?MODULE}, ?MODULE, [BaseDir], []).
  
  init([BaseDir]) ->
      defer_refresh(),
  
negative.code: 
  code_change(_OldVsn, State, _Extra) ->
      {ok, State}.
  
  %%
  %% Helpers
  %%
  
  log_open(FileName, DateHour) ->
      LogName = FileName ++ suffix(DateHour),
  