tcp client

This commit is contained in:
2025-06-30 11:20:09 +02:00
parent 2b9bcbc56f
commit a8ce309eac
3 changed files with 50 additions and 2 deletions

View File

@@ -124,6 +124,12 @@ extern readdir
extern closedir
extern exit
extern gettimeofday
extern connect
extern inet_addr
extern socket
extern send
extern read
extern close
section .text._builtin_deref
_builtin_deref:
@@ -245,6 +251,28 @@ _builtin_array_free:
mov rdi, rbx
pop rbx
jmp free
_builtin_sa_from_addr:
push r15
push r14
push rbx
mov rbx, rsi
mov r14, rdi
push 16
pop rdi
call malloc
mov r15, rax
mov dword [rax], 2
rol bx, 8
mov word [rax+2], bx
mov rdi, r14
call inet_addr
mov dword [r15+4], eax
mov rax, r15
pop rbx
pop r14
pop r15
ret
"
);
Ok(())