1.1.2 applied
This commit is contained in:
parent
53c73d8888
commit
771d40fab7
Binary file not shown.
@ -7,7 +7,7 @@
|
|||||||
; extension number 18
|
; extension number 18
|
||||||
ExtNb equ 18-1
|
ExtNb equ 18-1
|
||||||
Version MACRO
|
Version MACRO
|
||||||
dc.b "1.1.1-20240317"
|
dc.b "1.1.2-20240318"
|
||||||
ENDM
|
ENDM
|
||||||
VerNumber equ $1
|
VerNumber equ $1
|
||||||
|
|
||||||
@ -1374,10 +1374,24 @@ _SocketInetNtoA_StringSizeLoop:
|
|||||||
MOVE.L A0,D3
|
MOVE.L A0,D3
|
||||||
SUB.L A2,D3 ; D3 = length
|
SUB.L A2,D3 ; D3 = length
|
||||||
SUBQ #1,D3 ; get rid of the null terminator
|
SUBQ #1,D3 ; get rid of the null terminator
|
||||||
|
MOVE.L A0,D4
|
||||||
|
SUB.L A2,D4 ; D4 = length
|
||||||
|
SUBQ #1,D4 ; get rid of the null terminator
|
||||||
|
|
||||||
|
; add 2 and even out the space
|
||||||
|
MOVE.L D4,D3
|
||||||
|
AND.W #$FFFE,D3
|
||||||
|
ADDQ.W #2,D3
|
||||||
|
|
||||||
Rjsr L_Demande ; string base address is in A0/A1
|
Rjsr L_Demande ; string base address is in A0/A1
|
||||||
|
|
||||||
MOVE.W D3,(A0)+ ; length of string
|
LEA 2(A0,D3.W),A1
|
||||||
SUBQ #1,D3
|
|
||||||
|
MOVE.L A1,HiChaine(A5)
|
||||||
|
MOVE.L A0,A1
|
||||||
|
|
||||||
|
MOVE.W D4,(A0)+ ; length of string
|
||||||
|
SUBQ #1,D4
|
||||||
|
|
||||||
_SocketInetNtoA_StringCopyLoop:
|
_SocketInetNtoA_StringCopyLoop:
|
||||||
MOVE.B (A2,D3),(A0,D3)
|
MOVE.B (A2,D3),(A0,D3)
|
||||||
@ -1451,7 +1465,7 @@ _SocketRecvString_NotTooLong:
|
|||||||
_SocketRecvString_BufferAllocated:
|
_SocketRecvString_BufferAllocated:
|
||||||
MOVE.L D0,A0 ; buffer address
|
MOVE.L D0,A0 ; buffer address
|
||||||
MOVE.L D1,D0 ; socket
|
MOVE.L D1,D0 ; socket
|
||||||
MOVE.L (SP)+,D1 ; length
|
MOVE.L (SP)+,D1 ; reserved ram buffer length
|
||||||
MOVEQ #0,D2 ; flags
|
MOVEQ #0,D2 ; flags
|
||||||
|
|
||||||
MOVEM.L A0-A1/D1,-(SP)
|
MOVEM.L A0-A1/D1,-(SP)
|
||||||
@ -1479,39 +1493,38 @@ _SocketRecvString_BufferAllocated:
|
|||||||
Ret_String
|
Ret_String
|
||||||
|
|
||||||
; TODO received data is wrong somewhere
|
; TODO received data is wrong somewhere
|
||||||
|
|
||||||
_SocketRecvString_DataReceived:
|
_SocketRecvString_DataReceived:
|
||||||
; D0 contains receive length
|
; D0 contains socket receive length
|
||||||
|
|
||||||
MOVE.L D1,-(SP)
|
; TODO: handle zero return length
|
||||||
|
|
||||||
|
MOVE.L A0,A2 ; A2 contains read buffer
|
||||||
|
|
||||||
|
MOVE.L D1,-(SP) ; reserved ram buffer length
|
||||||
|
; demande/hichaine string setup
|
||||||
MOVEQ #0,D3
|
MOVEQ #0,D3
|
||||||
MOVE.W D0,D3 ; prep for L_Demande. can we request a zero length string?
|
MOVE.W D0,D3
|
||||||
MOVE.L A0,A2 ; L_Demande blows away A0 and A1, A2 now contains buffer
|
AND.W #$FFFE,D3
|
||||||
|
ADDQ #2,D3
|
||||||
Rjsr L_Demande ; A0/A1 contain string address
|
Rjsr L_Demande ; A0/A1 contain string address
|
||||||
|
|
||||||
MOVE.W D3,(A0)+ ; put in string length
|
LEA 2(A0,D3.W),A1
|
||||||
SUBQ #1,D3 ; reduce by one for DBRA
|
MOVE.L A1,HiChaine(A5)
|
||||||
|
MOVE.L A0,A1
|
||||||
|
|
||||||
|
MOVE.W D0,(A1)+ ; put in string length
|
||||||
|
SUBQ #1,D0 ; reduce by one for DBRA
|
||||||
MOVE.L A2,A3 ; A3 now contains start of buffer
|
MOVE.L A2,A3 ; A3 now contains start of buffer
|
||||||
|
|
||||||
_SocketRecvString_CopyData:
|
_SocketRecvString_CopyData:
|
||||||
MOVE.B (A2,D3),(A0,D3)
|
MOVE.B (A2,D0),(A1,D0)
|
||||||
DBRA D3,_SocketRecvString_CopyData
|
DBRA D0,_SocketRecvString_CopyData
|
||||||
|
MOVE.L (SP)+,D0 ; reserved ram buffer length
|
||||||
|
|
||||||
EvenOutStringAddress A0,D2
|
MOVE.L A0,-(SP)
|
||||||
|
|
||||||
; add to string manager for garbage collection?
|
|
||||||
MOVE.L A0,HiChaine(A5)
|
|
||||||
MOVE.L (SP)+,D0
|
|
||||||
|
|
||||||
; free ram
|
|
||||||
MOVE.L A1,-(SP) ; A1 contains our string addres
|
|
||||||
|
|
||||||
;MOVE.L D1,D0
|
|
||||||
MOVE.L A3,A1
|
MOVE.L A3,A1
|
||||||
Rjsr L_RamFree
|
Rjsr L_RamFree
|
||||||
|
|
||||||
MOVE.L (SP)+,D3 ; string return
|
MOVE.L (SP)+,D3 ; string return
|
||||||
|
|
||||||
MOVE.L (SP)+,A3
|
MOVE.L (SP)+,A3
|
||||||
|
|
||||||
RestoreStackFunction
|
RestoreStackFunction
|
||||||
@ -1905,7 +1918,7 @@ _SocketReuseAddr_LibraryOpen:
|
|||||||
|
|
||||||
|
|
||||||
; - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
|
; - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
|
||||||
; =Dns Get Host Address By Name$(Name String)
|
; =Dns Get Address By Name$(Name String)
|
||||||
;
|
;
|
||||||
; Get the status of a socket
|
; Get the status of a socket
|
||||||
; - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
|
; - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
|
||||||
@ -1986,18 +1999,22 @@ _DnsGetHostAddressByName_GetIPAddressLength:
|
|||||||
BNE _DnsGetHostAddressByName_GetIPAddressLength
|
BNE _DnsGetHostAddressByName_GetIPAddressLength
|
||||||
MOVE.L (SP)+,A2
|
MOVE.L (SP)+,A2
|
||||||
|
|
||||||
|
MOVE.L D3,D4
|
||||||
|
AND.W #$FFFE,D3
|
||||||
|
ADDQ #2,D3
|
||||||
|
|
||||||
Rjsr L_Demande ; string is in A0/A1
|
Rjsr L_Demande ; string is in A0/A1
|
||||||
MOVE.W D3,(A0)+
|
|
||||||
SUBQ #1,D3
|
LEA 2(A0,D3.W),A1
|
||||||
|
MOVE.L A1,HiChaine(A5)
|
||||||
|
MOVE.L A0,D3
|
||||||
|
|
||||||
|
MOVE.W D4,(A0)+
|
||||||
|
SUBQ #1,D4
|
||||||
|
|
||||||
_DnsGetHostAddressByName_KeepCopying:
|
_DnsGetHostAddressByName_KeepCopying:
|
||||||
MOVE.B (A2,D3),(A0,D3)
|
MOVE.B (A2,D4),(A0,D4)
|
||||||
DBRA D3,_DnsGetHostAddressByName_KeepCopying
|
DBRA D4,_DnsGetHostAddressByName_KeepCopying
|
||||||
|
|
||||||
EvenOutStringAddress A0,D0
|
|
||||||
|
|
||||||
MOVE.L A0,HiChaine(A5)
|
|
||||||
MOVE.L A1,D3
|
|
||||||
|
|
||||||
RestoreStackFunction
|
RestoreStackFunction
|
||||||
|
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
; ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
; ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
||||||
; BSDSocket.s, list of the library functions on the 25-04-2024 14:44:28
|
; BSDSocket.s, list of the library functions on the 25-04-2024 16:01:54
|
||||||
;
|
;
|
||||||
; ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
; ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
||||||
L_Cold: set 0
|
L_Cold: set 0
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
; ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
; ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
||||||
; BSDSocket.s, library size on the 25-04-2024 14:44:28
|
; BSDSocket.s, library size on the 25-04-2024 16:01:54
|
||||||
;
|
;
|
||||||
; ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
; ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
||||||
Lib_Size equ 39
|
Lib_Size equ 39
|
||||||
|
Loading…
Reference in New Issue
Block a user