anchor.diff:      State3 = gui_clear(State2),
       State4 = gui_nop(#gres{state=tailing,loop= <<"tail">>},State3),
       {next_state, tailing, State4#state{tailMode=true,tailLock=false}};
  +completed({button, <<"pt">>, ReplyTo}, #state{nav=ind}=State0) ->
  +    % reject command because of uncommitted changes
  +    State1 = gui_nop(#gres{state=completed,beep=true,message= ?PtNoSort},State0#state{replyToFun=ReplyTo}),
  +    {next_state, completed, State1};
   completed({button, <<"pt">>, ReplyTo}, #state{dirtyCnt=DC}=State0) when DC==0 ->
       % passthrough, schedule tail
       State1 = reply_stack(completed, ReplyTo, State0),
  -    State2 = fetch(push,true,State1#state{tailMode=true,tailLock=false}),
  -    State3 = data_clear(State2),
  -    State4 = gui_clear(#gres{state=passthrough,loop= <<"tail">>}, State3),
  +    State2 = data_clear(State1),
  +    State3 = gui_clear(#gres{state=passthrough,loop= <<"tail">>}, State2),
  +    State4 = fetch(push,true,State3#state{tailMode=true,tailLock=false}),
       {next_state, passthrough, State4};
   completed({button, <<"pt">>, ReplyTo}, State0) ->
       % reject command because of uncommitted changes
  
positive.code:             %% no data, serve empty
              State1 = prefetch(SN,State0),
              gui_clear(#gres{state=SN,loop=Loop},State1);
          (GuiCnt == 0) ->
              %% uninitialized view, must refresh    
              gui_replace_until(BufBot,GL,#gres{state=SN,loop=Loop,focus=-1},State0); % was BL
          (GuiCol == true) ->
              %% dirty index view, must refresh anyways    
              gui_replace_until(BufBot,GL,#gres{state=SN,loop=Loop,focus=-1},State0); % was BL
          (Loop == <<"tail">>) andalso (SN == passthrough) ->
              %% passthrough should always append only               
              gui_append(#gres{state=SN,loop=Loop,focus=-1},State0#state{tailLock=false});
          (GuiTop > BufTop) andalso (GuiCnt < GL) ->                                  % was BL
              %% prepend incomplete gui buffer
              gui_replace_until(BufBot,GL,#gres{state=SN,loop=Loop,focus=-1},State0); % was BL
  
negative.code:     Fsm = {?MODULE,self()},
      Fsm:rows({Rows,Completed}),
      {next_state, SN, State, infinity};
  handle_info(cmd_stack_timeout, SN, #state{stack={button, <<"tail">>, RT}}=State)
      when SN =:= tailing; SN =:= passthrough ->
      % we didn't get any new data to send, so we reply with nop.
      ?NoDbLog(debug, [], "Tail timeout, replying with nop", []),
      State1 = gui_nop(#gres{state=SN, loop= <<"tail">>, focus=-1},State#state{stack=undefined,replyToFun=RT,tRef=undefined}),
      {next_state, SN, State1, infinity};
  handle_info({'EXIT', _Pid, Reason} = ExitMsg, _SN, State) ->
      ?Debug("~p received exit message ~p", [self(), ExitMsg]),
      {stop, Reason, State};
  