Function at 0x409b40
Capabilities:
Read file on windows

Disassembly:
push ebp
push edi
push esi
push ebx
sub esp, 0x7c
mov dword [esp + 0x38], edx
mov edx, dword [0x418140]
mov dword [esp + 0x3c], eax
test edx, edx
jne 0x409e4d
xor eax, eax
mov dword [esp + 8], eax
xor eax, eax
mov dword [esp + 4], eax
mov eax, dword [esp + 0x3c]
mov dword [esp], eax
call sub.msvcrt.dll__open
test eax, eax
mov edi, eax
js 0x40a292
mov ecx, dword [esp + 0x3c]
lea eax, [esp + 0x40]
mov dword [esp + 4], eax
mov dword [esp], ecx
call sub.msvcrt.dll__stat
test eax, eax
js 0x40a286
mov eax, dword [esp + 0x54]
inc eax
mov dword [esp], eax
call fcn.0040e5d0
mov dword [esp], edi
mov ebx, eax
mov eax, dword [esp + 0x54]
mov dword [esp + 4], ebx
mov dword [esp + 8], eax
call sub.msvcrt.dll__read
test eax, eax
mov esi, eax
js 0x40a27a
mov byte [eax + ebx], 0
mov dword [esp], edi
call sub.msvcrt.dll__close
lea eax, [esi + 1]
mov dword [esp], eax
call fcn.0040e5d0
mov dword [esp + 0x34], eax
test ebx, ebx
mov ecx, eax
mov edx, ebx
je 0x409c15
movzx eax, byte [ebx]
test al, al
je 0x409c15
lea esi, [esi]
lea edi, [edi]
cmp al, 0xd
je 0x409d03
mov byte [ecx], al
inc ecx
inc edx
je 0x409c15
movzx eax, byte [edx]
test al, al
jne 0x409c00
mov byte [ecx], 0
mov dword [esp], ebx
call sub.msvcrt.dll_free
mov ebp, dword [esp + 0x34]
mov eax, ebp
call fcn.004012f0
movzx ebx, byte [eax]
mov ebp, eax
test bl, bl
je 0x40a2b4
cmp bl, 0x25
sete al
xor edx, edx
cmp dword [esp + 0x38], 0
sete dl
test eax, edx
je 0x409e00
mov dword [esp + 0x1c], ebp
cmp bl, 0xa
jmp 0x409c74
inc ebp
movzx eax, byte [ebp]
test al, al
setne dl
cmp al, 0xa
setne al
movzx eax, al
test edx, eax
jne 0x409c60
cld
mov esi, dword [esp + 0x1c]
mov eax, str._include
mov ecx, 8
mov edi, eax
inc ebp
repe cmpsb byte [esi], byte es:[edi]
jne 0x409d22
mov edx, dword [esp + 0x1c]
movzx eax, byte [edx + 8]
cmp al, 0x20
sete dl
cmp al, 9
sete al
or eax, edx
test al, 1
je 0x409d22
add dword [esp + 0x1c], 9
mov edi, dword [esp + 0x1c]
movzx ecx, byte [edi]
jmp 0x409cc1
inc dword [esp + 0x1c]
mov eax, dword [esp + 0x1c]
movzx ecx, byte [eax]
cmp cl, 0x20
sete al
cmp cl, 9
sete dl
or eax, edx
test al, 1
jne 0x409cb6
inc dword [esp + 0x1c]
cmp cl, 0x3c
jne 0x409ce6
cmp byte [ebp - 2], 0x3e
je 0x40a24a
mov dword [esp], str.specs___include_syntax_malformed_after__ld_characters
mov edx, dword [esp + 0x34]
sub dword [esp + 0x1c], edx
mov eax, dword [esp + 0x1c]
inc eax
mov dword [esp + 4], eax
call fcn.00403300
cmp edx, ebx
jbe 0x409d11
cmp byte [edx - 1], 0xa
je 0x409c0b
cmp byte [edx + 1], 0xa
je 0x409c0b
mov al, 0xa
jmp 0x409c08
cld
mov esi, dword [esp + 0x1c]
mov eax, str._include_noerr
mov ecx, 0xe
mov edi, eax
repe cmpsb byte [esi], byte es:[edi]
jne 0x409d53
mov edx, dword [esp + 0x1c]
movzx eax, byte [edx + 0xe]
cmp al, 0x20
sete dl
cmp al, 9
sete al
or eax, edx
test al, 1
jne 0x409fc1
cld
mov esi, dword [esp + 0x1c]
mov eax, str._rename
mov ecx, 7
mov edi, eax
repe cmpsb byte [esi], byte es:[edi]
jne 0x40a2c9
mov edx, dword [esp + 0x1c]
movzx eax, byte [edx + 7]
cmp al, 0x20
sete dl
cmp al, 9
sete al
or eax, edx
test al, 1
je 0x40a2c9
add dword [esp + 0x1c], 8
mov edi, dword [esp + 0x1c]
movzx ecx, byte [edi]
jmp 0x409da1
inc dword [esp + 0x1c]
mov eax, dword [esp + 0x1c]
movzx ecx, byte [eax]
cmp cl, 0x20
sete al
cmp cl, 9
sete dl
or eax, edx
test al, 1
jne 0x409d96
movzx eax, cl
movzx eax, word [eax + eax + 0x417630]
test al, 0x88
je 0x40a358
test cl, cl
mov ebx, dword [esp + 0x1c]
je 0x40a223
test al, 0x40
jne 0x40a037
lea esi, [esi]
inc ebx
movzx ecx, byte [ebx]
test cl, cl
je 0x40a03e
movzx eax, cl
test byte [eax + eax + 0x417630], 0x40
je 0x409de0
jmp 0x40a03e
mov dword [esp + 0x1c], ebp
cmp bl, 0x3a
je 0x409e62
cmp bl, 0xa
mov cl, 0xa
je 0x409e66
inc dword [esp + 0x1c]
mov edi, dword [esp + 0x1c]
movzx ecx, byte [edi]
test cl, cl
setne al
xor edx, edx
cmp cl, 0x3a
setne dl
test eax, edx
je 0x409e66
cmp cl, 0xa
jne 0x409e10
mov eax, dword [esp + 0x34]
sub dword [esp + 0x1c], eax
mov edx, dword [esp + 0x1c]
mov dword [esp + 4], edx
mov dword [esp], str.specs_file_malformed_after__ld_characters
call fcn.00403300
mov dword [esp + 4], eax
mov dword [esp], str.Reading_specs_from__s_n
call fcn.00403910
jmp 0x409b5d
movzx ecx, byte [ebp]
cmp cl, 0x3a
jne 0x409e31
mov ebx, dword [esp + 0x1c]
mov ecx, dword [esp + 0x34]
cmp ebx, ecx
jbe 0x409ea0
mov esi, esi
lea edi, [edi]
movzx eax, byte [ebx - 1]
cmp al, 0x20
sete dl
cmp al, 9
sete al
or eax, edx
test al, 1
je 0x409ea0
dec ebx
cmp ebx, dword [esp + 0x34]
ja 0x409e80
nop
lea esi, [esi]
sub ebx, ebp
mov eax, ebp
mov edx, ebx
call fcn.00401620
mov dword [esp + 0x30], eax
mov eax, dword [esp + 0x1c]
inc eax
call fcn.004012f0
movzx edx, byte [eax + 1]
mov ebp, eax
test dl, dl
je 0x40a314
mov dword [esp + 0x1c], eax
movzx eax, byte [eax]
test al, al
je 0x409f08
cmp al, 0xa
je 0x40a242
lea esi, [esi]
inc dword [esp + 0x1c]
mov edi, dword [esp + 0x1c]
movzx eax, byte [edi]
test al, al
je 0x409f08
cmp al, 0xa
jne 0x409ee0
movzx eax, byte [edi + 1]
cmp al, 0xa
setne dl
test al, al
setne al
movzx eax, al
test edx, eax
jne 0x409ee0
mov edx, dword [esp + 0x1c]
mov eax, ebp
sub edx, ebp
call fcn.00401620
mov dword [esp + 0x2c], eax
mov esi, eax
mov ebx, eax
movzx eax, byte [eax]
mov ebp, dword [esp + 0x1c]
test al, al
je 0x409f49
mov cl, al
lea esi, [esi]
cmp cl, 0x5c
je 0x40a1b5
cmp cl, 0x23
je 0x409f95
mov byte [ebx], cl
inc esi
inc ebx
movzx ecx, byte [esi]
test cl, cl
jne 0x409f30
mov byte [ebx], 0
mov ecx, dword [esp + 0x30]
cmp byte [ecx], 0x2a
jne 0x40a1c7
cld
mov esi, dword [esp + 0x30]
mov edi, str.link_command
mov ecx, 0xe
repe cmpsb byte [esi], byte es:[edi]
jne 0x40a22f
mov edi, dword [esp + 0x2c]
mov dword [str.__fsyntax_only:__c:__M:__MM:__E:__S:______linker___l__pie:_pie__X__o__A__d__e__m__N__n__r_____s__t__u__x__z__Z___A:__nostdlib:__nostartfiles:_S_____static:__L___link_libgcc___o__fprofile_arcsfprofile_generate:_lgcov______nostdlib:__nodefaultlibs:__link_gcc_c_sequence_______A:__nostdlib:__nostartfiles:_E__T_], edi
mov edi, dword [esp + 0x30]
cmp byte [edi], 0
jne 0x409c24
mov eax, dword [esp + 0x2c]
mov dword [str.__fsyntax_only:__c:__M:__MM:__E:__S:______linker___l__pie:_pie__X__o__A__d__e__m__N__n__r_____s__t__u__x__z__Z___A:__nostdlib:__nostartfiles:_S_____static:__L___link_libgcc___o__fprofile_arcsfprofile_generate:_lgcov______nostdlib:__nodefaultlibs:__link_gcc_c_sequence_______A:__nostdlib:__nostartfiles:_E__T_], eax
jmp 0x409c24
inc esi
movzx ecx, byte [esi]
test cl, cl
setne al
xor edx, edx
cmp cl, 0xa
setne dl
test eax, edx
je 0x409f45
inc esi
movzx ecx, byte [esi]
test cl, cl
setne al
xor edx, edx
cmp cl, 0xa
setne dl
test eax, edx
jne 0x409f95
jmp 0x409f45
add dword [esp + 0x1c], 0xf
mov edi, dword [esp + 0x1c]
movzx ecx, byte [edi]
jmp 0x409fdb
inc dword [esp + 0x1c]
mov eax, dword [esp + 0x1c]
movzx ecx, byte [eax]
cmp cl, 0x20
sete al
cmp cl, 9
sete dl
or eax, edx
test al, 1
jne 0x409fd0
inc dword [esp + 0x1c]
cmp cl, 0x3c
jne 0x409ce6
cmp byte [ebp - 2], 0x3e
jne 0x409ce6
mov byte [ebp - 2], 0
xor eax, eax
mov edx, dword [esp + 0x1c]
mov dword [esp + 4], eax
mov eax, 0x411034
mov dword [esp], 4
call fcn.00401d60
test eax, eax
je 0x40a323
xor edx, edx
call fcn.00409b40
jmp 0x409c24
mov eax, dword [esp + 0x1c]
movzx ecx, byte [eax]
cmp cl, 0x20
setne al
xor edx, edx
cmp cl, 9
setne dl
test eax, edx
jne 0x40a29e
mov esi, dword [esp + 0x1c]
mov edx, ebx
sub edx, esi
mov dword [esp + 0x28], edx
mov byte [ebx], 0
lea esi, [esi]
lea edi, [edi]
inc ebx
movzx ecx, byte [ebx]
cmp cl, 0x20
sete al
cmp cl, 9
sete dl
or eax, edx
test al, 1
jne 0x40a070
movzx eax, cl
movzx eax, word [eax + eax + 0x417630]
test al, 0x88
je 0x40a29e
test cl, cl
mov edx, ebx
je 0x40a0c5
test al, 0x40
jne 0x40a0c5
lea esi, [esi]
lea edi, [edi]
inc edx
movzx eax, byte [edx]
test al, al
je 0x40a0c5
movzx eax, al
test byte [eax + eax + 0x417630], 0x40
je 0x40a0b0
lea eax, [ebp - 1]
cmp eax, edx
jne 0x40a349
mov byte [ebp - 1], 0
mov esi, dword [0x4180a0]
test esi, esi
mov dword [esp + 0x20], esi
je 0x40a100
lea esi, [esi]
lea edi, [edi]
mov ecx, dword [esp + 0x28]
cmp dword [esi + 0x10], ecx
je 0x40a114
mov esi, dword [esi + 0xc]
test esi, esi
jne 0x40a0f0
mov dword [esp], str.specs__s_spec_was_not_found_to_be_renamed
mov eax, dword [esp + 0x1c]
mov dword [esp + 4], eax
call fcn.00403300
mov edi, dword [esp + 0x1c]
mov dword [esp + 4], edi
mov eax, dword [esi]
mov dword [esp], eax
call sub.msvcrt.dll_strcmp
test eax, eax
jne 0x40a0f9
test esi, esi
je 0x40a100
mov dword [esp + 4], ebx
mov edx, dword [esp + 0x1c]
mov dword [esp], edx
call sub.msvcrt.dll_strcmp
test eax, eax
je 0x409c24
mov ecx, dword [esp + 0x20]
test ecx, ecx
mov dword [esp + 0x24], ecx
je 0x40a17b
mov dword [esp + 4], ebx
mov edi, dword [esp + 0x24]
mov eax, dword [edi]
mov dword [esp], eax
call sub.msvcrt.dll_strcmp
test eax, eax
je 0x40a36d
mov ecx, dword [esp + 0x24]
mov ecx, dword [ecx + 0xc]
mov dword [esp + 0x24], ecx
test ecx, ecx
jne 0x40a152
mov ecx, dword [0x418140]
test ecx, ecx
jne 0x40a2f7
mov eax, dword [esi + 8]
mov edx, dword [eax]
mov eax, ebx
call fcn.00401350
mov edx, dword [esi + 0x14]
test edx, edx
jne 0x40a2e5
mov dword [esi + 0x14], 0
mov eax, dword [esi + 8]
mov dword [eax], 0x41237c
jmp 0x409c24
cmp byte [esi + 1], 0xa
jne 0x409f3e
add esi, 2
jmp 0x409f42
mov eax, dword [0x4182d0]
lea eax, [eax + eax*2]
lea eax, [eax*4 + 0x18]
mov dword [esp + 4], eax
mov eax, dword [0x4182c0]
mov dword [esp], eax
call fcn.0040e660
mov dword [0x4182c0], eax
mov edi, dword [0x4182d0]
cld
mov ecx, dword [esp + 0x30]
lea edx, [edi + edi*2]
shl edx, 2
inc edi
mov dword [edx + eax], ecx
mov ecx, dword [esp + 0x2c]
mov dword [0x4182d0], edi
lea edi, [edi + edi*2]
lea edi, [eax + edi*4]
mov dword [edx + eax + 4], ecx
mov ecx, 3
xor eax, eax
rep stosd dword es:[edi], eax
jmp 0x409f7a
mov edi, dword [esp + 0x1c]
movzx ecx, byte [edi]
jmp 0x40a03e
mov eax, dword [esp + 0x30]
mov edx, dword [esp + 0x2c]
inc eax
call fcn.00401350
jmp 0x409f7a
cmp dl, 0xa
jmp 0x409f06
mov byte [ebp - 2], 0
xor eax, eax
mov edx, dword [esp + 0x1c]
mov dword [esp + 4], eax
mov eax, 0x411034
mov dword [esp], 4
call fcn.00401d60
test eax, eax
jne 0x40a02b
mov eax, dword [esp + 0x1c]
jmp 0x40a02b
mov eax, dword [esp + 0x3c]
mov dword [esp], eax
call fcn.004030c0
mov edi, dword [esp + 0x3c]
mov dword [esp], edi
call fcn.004030c0
mov edx, dword [esp + 0x3c]
mov dword [esp], edx
call fcn.004030c0
mov edi, dword [esp + 0x34]
sub ebx, edi
mov dword [esp + 4], ebx
mov dword [esp], str.specs___rename_syntax_malformed_after__ld_characters
call fcn.00403300
mov eax, dword [str.__fsyntax_only:__c:__M:__MM:__E:__S:______linker___l__pie:_pie__X__o__A__d__e__m__N__n__r_____s__t__u__x__z__Z___A:__nostdlib:__nostartfiles:_S_____static:__L___link_libgcc___o__fprofile_arcsfprofile_generate:_lgcov______nostdlib:__nodefaultlibs:__link_gcc_c_sequence_______A:__nostdlib:__nostartfiles:_E__T_]
test eax, eax
je 0x40a38d
add esp, 0x7c
pop ebx
pop esi
pop edi
pop ebp
ret
mov dword [esp], str.specs_unknown____command_after__ld_characters
mov eax, dword [esp + 0x34]
sub dword [esp + 0x1c], eax
mov edx, dword [esp + 0x1c]
mov dword [esp + 4], edx
call fcn.00403300
mov eax, dword [esi + 8]
mov eax, dword [eax]
mov dword [esp], eax
call sub.msvcrt.dll_free
jmp 0x40a1a0
mov dword [esp + 8], ebx
mov edi, dword [esp + 0x1c]
mov dword [esp], str.rename_spec__s_to__s_n
mov dword [esp + 4], edi
call fcn.00403910
jmp 0x40a189
mov eax, dword [esp + 0x34]
sub ebp, eax
mov dword [esp + 4], ebp
jmp 0x409e41
mov eax, dword [0x418140]
test eax, eax
je 0x409c24
mov dword [esp], str.could_not_find_specs_file__s_n
mov ecx, dword [esp + 0x1c]
mov dword [esp + 4], ecx
call fcn.00403910
jmp 0x409c24
mov ebx, dword [esp + 0x34]
sub edx, ebx
mov dword [esp + 4], edx
jmp 0x40a2a8
mov edx, dword [esp + 0x34]
sub dword [esp + 0x1c], edx
mov ecx, dword [esp + 0x1c]
mov dword [esp + 4], ecx
jmp 0x40a2a8
mov dword [esp + 0xc], ebx
mov eax, dword [esp + 0x1c]
mov edx, dword [esp + 0x3c]
mov dword [esp], str._s:_attempt_to_rename_spec__s_to_already_defined_spec__s
mov dword [esp + 8], eax
mov dword [esp + 4], edx
call fcn.00403300
mov dword [esp], str.spec_file_has_no_spec_for_linking
call fcn.00403300
lea esi, [esi]