Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- section .data
- filename: db 'hello.txt',0
- text: db 'Hello World!',10
- textLen: equ $-text
- section .bss
- fd: resb 4
- section .text
- global _start
- _start:
- mov eax,8
- mov ebx,filename
- mov ecx,1
- int 80h
- mov [fd],eax
- mov eax,15
- mov ebx,filename
- mov ecx,420
- int 80h
- mov ebx,[fd]
- mov eax,4
- mov ecx,text
- mov edx,textLen
- int 80h
- mov eax,1
- mov ebx,0
- int 80h
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement