diff --git a/LIB/LIBTCPIP.S.IP.txt b/LIB/LIBTCPIP.S.IP.txt index b942a68a..2265c595 100644 --- a/LIB/LIBTCPIP.S.IP.txt +++ b/LIB/LIBTCPIP.S.IP.txt @@ -18,7 +18,7 @@ IP.IN ldy #S.IP.PROTOCOL .3 cmp #S.IP.PROTOCOL.TCP bne .9 - jmp TCP.IN + jsr TCP.IN TCP will NOT discard FrameIn .9 lda hFrameIn >SYSCALL FreeMemA diff --git a/LIB/LIBTCPIP.S.TCP.txt b/LIB/LIBTCPIP.S.TCP.txt index 36dd6165..ccd39505 100644 --- a/LIB/LIBTCPIP.S.TCP.txt +++ b/LIB/LIBTCPIP.S.TCP.txt @@ -151,7 +151,7 @@ TCP.IN.JMP.LISTEN .99 rts *-------------------------------------- TCP.IN.JMP.SYNSENT - ldy #S.TCP.OPTIONS SYN Stend, only accept SYN.ACK packet, then Send ACK + ldy #S.TCP.OPTIONS SYN Send, only accept SYN.ACK packet, then Send ACK lda (ZPFrameInPtr),y cmp #S.TCP.OPTIONS.SYN+S.TCP.OPTIONS.ACK bne .8 @@ -222,20 +222,19 @@ TCP.IN.JMP.ESTBLSH ldy #S.TCP.OPTIONS lda (ZPFrameInPtr),y - bit #S.TCP.OPTIONS.ACK + bit #S.TCP.OPTIONS.ACK Remote side ACKed data ? beq .1 - jsr SKT.AckDataToSktOut + jsr SKT.AckDataToSktOut Yes, Discard sent data .1 jsr TCP.IN.SetDataInPtrAndLen - lda ZPDataInLen + lda ZPDataInLen Incoming Data in this frame ? ora ZPDataInLen+1 - beq .2 No data in this incoming frame... - - jsr SKT.AddDataToSktIn - bcs .9 + beq .2 No data, ... + jsr SKT.AddDataToSktIn yes, queue data if there is room for.... + .2 ldy #S.TCP.OPTIONS lda (ZPFrameInPtr),y bit #S.TCP.OPTIONS.FIN @@ -245,11 +244,6 @@ TCP.IN.JMP.ESTBLSH lda #S.SOCKET.TCP.STATUS.CLWAIT sta (ZPPtrSKT),y - ldy #S.SOCKET.TCP.OPTIONS - lda (ZPPtrSKT),y - ora #S.TCP.OPTIONS.ACK - sta (ZPPtrSKT),y - .8 jmp TCP.OUT.I .9 rts *--------------------------------------