Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- SECTION .data ; Section containing initialized data
- EatMsg: db "Eat at Joe's!",10
- EatLen: equ $-EatMsg
- SECTION .bss ; Section containing uninitialized data
- SECTION .text ; Section containing code
- global start ; Linker needs this to find the entry point!
- start:
- nop ; This no-op keeps gdb happy...
- mov eax,4 ; Specify sys_write call
- mov ebx,1 ; Specify File Descriptor 1: Standard Output
- mov ecx,EatMsg ; Pass offset of the message
- mov edx,EatLen ; Pass the length of the message
- int 80H ; Make kernel call
- mov eax,1 ; Code for Exit Syscall
- mov ebx,0 ; Return a code of zero
- int 80H ; Make kernel call
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement