Created
August 22, 2014 04:11
-
-
Save Endle/cd5f4ee2d5301b697fa0 to your computer and use it in GitHub Desktop.
Code sample for HrbLUG
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
.file "sample.c" | |
.def ___main; .scl 2; .type 32; .endef | |
.section .rdata,"dr" | |
LC0: | |
.ascii "C:\\sample.txt\0" | |
.text | |
.globl _main | |
.def _main; .scl 2; .type 32; .endef | |
_main: | |
leal 4(%esp), %ecx | |
andl $-16, %esp | |
pushl -4(%ecx) | |
pushl %ebp | |
movl %esp, %ebp | |
pushl %ecx | |
subl $20, %esp | |
call ___main | |
movl $LC0, (%esp) | |
call _DeleteFileA@4 | |
subl $4, %esp | |
movl $0, %eax | |
movl -4(%ebp), %ecx | |
leave | |
leal -4(%ecx), %esp | |
ret | |
.def _DeleteFileA@4; .scl 2; .type 32; .endef |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment