Skip to content

Commit

Permalink
delete logging
Browse files Browse the repository at this point in the history
  • Loading branch information
DavidAlphaFox committed Oct 4, 2021
1 parent 765948c commit 5455b57
Show file tree
Hide file tree
Showing 3 changed files with 2 additions and 5 deletions.
3 changes: 1 addition & 2 deletions src/aiutp_net.erl
Original file line number Diff line number Diff line change
Expand Up @@ -122,9 +122,8 @@ send_ack(#aiutp_pcb{time = Now,
PCB#aiutp_pcb{last_sent_packet = Now,last_rcv_win = WindowSize}.


send_keep_alive(#aiutp_pcb{conn_id_recv = ConnId,ack_nr = AckNR} = PCB)->
send_keep_alive(#aiutp_pcb{ack_nr = AckNR} = PCB)->
PCB0 = send_ack(PCB#aiutp_pcb{ack_nr = aiutp_util:bit16(AckNR -1)}),
io:format("ConnId:~p send keep alive: ~p~n",[ConnId,AckNR]),
PCB0#aiutp_pcb{ack_nr = AckNR}.

update_wrap_packet(MicroNow,ReplyMicro,WindowSize,AckNR,WrapPacket)->
Expand Down
1 change: 0 additions & 1 deletion src/aiutp_rx.erl
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,6 @@
in(#aiutp_packet{seq_nr = PktSeqNR} = Packet,
#aiutp_pcb{ack_nr = AckNR} = PCB)->
NextAckNR = aiutp_util:bit16(AckNR + 1),
io:format("recv: ~p expect: ~p~n",[PktSeqNR,NextAckNR]),
PCB1 =
if PktSeqNR == NextAckNR -> recv(Packet,PCB#aiutp_pcb{ack_nr = PktSeqNR});
true-> recv_reorder(aiutp_util:bit16(PktSeqNR - NextAckNR),Packet,PCB)
Expand Down
3 changes: 1 addition & 2 deletions src/aiutp_worker.erl
Original file line number Diff line number Diff line change
Expand Up @@ -423,8 +423,7 @@ active_read(#state{parent = Parent,
Control ! {utp_data,UTPSocket,Payload},
{false,PCB1}
end,
PCB3 = aiutp_pcb:flush(PCB2),
State#state{ active = Active,pcb = PCB3};
State#state{ active = Active,pcb = PCB2};
active_read(#state{pcb = PCB} = State)->
PCB1 = aiutp_pcb:flush(PCB),
State#state{pcb = PCB1}.
Expand Down

0 comments on commit 5455b57

Please sign in to comment.