mirror of
https://github.com/A2osX/A2osX.git
synced 2024-11-29 17:50:18 +00:00
53 lines
865 B
Plaintext
53 lines
865 B
Plaintext
NEW
|
||
PREFIX /A2OSX.BUILD
|
||
AUTO 4,1
|
||
.LIST OFF
|
||
*--------------------------------------
|
||
HST.GetByName >PULLW ZPPtrDNS
|
||
>PULLW ZPPtrIP
|
||
|
||
lda ZPPtrIP
|
||
clc
|
||
adc #3
|
||
tay
|
||
lda ZPPtrIP+1
|
||
adc #0
|
||
>PUSHYA @IP[3]
|
||
|
||
lda ZPPtrIP
|
||
clc
|
||
adc #2
|
||
tay
|
||
lda ZPPtrIP+1
|
||
adc #0
|
||
>PUSHYA @IP[2]
|
||
|
||
>LDYA ZPPtrIP
|
||
iny
|
||
bne .1
|
||
inc
|
||
.1 >PUSHYA @IP[1]
|
||
|
||
>PUSHW ZPPtrIP @IP[0]
|
||
|
||
>PUSHBI 8 4 PTRs on stack
|
||
>PUSHW L.HST.SScanF
|
||
>LDYA ZPPtrDNS
|
||
|
||
>SYSCALL SScanF
|
||
bcc .9
|
||
jmp DNS.QUERY.I
|
||
.9 rts
|
||
*--------------------------------------
|
||
HST.GetByAddr >PULLW ZPPtrIP
|
||
>PULLW ZPPtrDNS
|
||
|
||
|
||
sec
|
||
rts
|
||
*--------------------------------------
|
||
MAN
|
||
SAVE /A2OSX.SRC/LIB/LIBTCPIP.S.HST
|
||
LOAD /A2OSX.SRC/LIB/LIBTCPIP.S
|
||
ASM
|