Read from the file mov rax, mov rdi, mov rsi, mov rdx, syscall ; SYS_read qword [fileDescr] readBuffer BUFF_SIZE ; print
-
correctanswer
- Posts: 43759
- Joined: Sat Aug 07, 2021 7:38 am
Read from the file mov rax, mov rdi, mov rsi, mov rdx, syscall ; SYS_read qword [fileDescr] readBuffer BUFF_SIZE ; print
Read from the file mov rax, mov rdi, mov rsi, mov rdx, syscall ; SYS_read qword [fileDescr] readBuffer BUFF_SIZE ; print the buffer ; add null for the print string mov rsi, mov byte [rsi+rax], NULL mov rdi, call printString printNewLine Close the file mov rax, SYS_close mov rdi, qword [fileDescr] syscall Program done readBuffer readBuffer I
Register for solutions, replies, and use board search function. Answer Happy Forum is an archive of questions covering all technical subjects across the Internet.