Function at 0x3257000
Capabilities:
Get file size

Disassembly:
sub esp, 8
mov ecx, dword [esp + 0x10]
xor edx, edx
push ebx
push esi
xor ebx, ebx
mov dword [esp + 8], edx
xor eax, eax
mov dword [esp + 0x18], edx
mov esi, ecx
push edi
mov edi, dword [esp + 0x18]
test cl, 2
je 0x3257054
lea ebx, [edx + 4]
mov dword [esp + 0x1c], 2
mov edx, ecx
lea eax, [ebx - 3]
and ecx, 0xfffffffe
and edx, 1
cmove ecx, esi
shl edx, 0x1f
add edx, 0x40000000
test bl, cl
je 0x3257054
lea ebx, [eax + 0x3f]
mov dword [esp + 0x1c], 0x22
test cl, 1
je 0x3257083
mov dword [esp + 0x1c], 4
mov ebx, 2
mov edx, 0x80000000
lea eax, [ebx - 1]
test cl, 4
je 0x3257083
lea ebx, [eax + 0x1f]
mov dword [esp + 0x1c], 0x24
and ecx, 8
jmp 0x325708e
and ecx, 8
test eax, eax
je 0x3257257
mov esi, dword [esp + 0x20]
test esi, esi
je 0x3257257
push ebp
push 0
push 0x80
push 3
xor eax, eax
mov dword [esi], 0
test ecx, ecx
mov ebp, 3
push 0
cmove eax, ebp
push eax
push edx
push edi
call dword [sym.imp.KERNEL32.dll_CreateFileW]
mov ebp, eax
cmp ebp, 0xffffffff
jne 0x3257108
push 2
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
call fcn.03257780
mov esi, eax
push esi
push edi
push str.file_map_create
push 0x5b
push str..._srcwin_file_map.c
push str.__s:_d__ERR___s:_cannot_map_file__S__retcode__d_n
push 0
call fcn.0325f280
mov edi, dword [sym.imp.KERNEL32.dll_CloseHandle]
add esp, 0x24
push ebp
call edi
pop ebp
pop edi
mov eax, esi
pop esi
pop ebx
add esp, 8
ret
lea eax, [esp + 0x10]
push eax
push ebp
call dword [sym.imp.KERNEL32.dll_GetFileSize]
mov dword [esp + 0x14], eax
cmp eax, 0xffffffff
je 0x3257213
cmp dword [esp + 0x10], 0
jne 0x3257213
push 0
push eax
push 0
push ebx
push 0
push ebp
call dword [sym.imp.KERNEL32.dll_CreateFileMappingA]
mov ebx, eax
test ebx, ebx
jne 0x325714b
push 0x2712
jmp 0x3257215
push dword [esp + 0x14]
push 0
push 0
push dword [esp + 0x2c]
push ebx
call dword [sym.imp.KERNEL32.dll_MapViewOfFile]
mov dword [esp + 0x20], eax
test eax, eax
jne 0x32571a4
push 0x2712
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
call fcn.03257780
mov esi, eax
push esi
push edi
push str.file_map_create
push 0x5b
push str..._srcwin_file_map.c
push str.__s:_d__ERR___s:_cannot_map_file__S__retcode__d_n
push 0
call fcn.0325f280
mov edi, dword [sym.imp.KERNEL32.dll_CloseHandle]
add esp, 0x24
push ebx
call edi
jmp 0x3257246
push 0x18
call fcn.0339076d
add esp, 4
mov dword [esi], eax
test eax, eax
jne 0x32571e9
lea esi, [eax + 0xc]
push esi
push edi
push str.file_map_create
push 0x5b
push str..._srcwin_file_map.c
push str.__s:_d__ERR___s:_cannot_map_file__S__retcode__d_n
push eax
call fcn.0325f280
add esp, 0x1c
mov ecx, dword [esp + 0x20]
push ecx
call dword [sym.imp.KERNEL32.dll_UnmapViewOfFile]
mov edi, dword [sym.imp.KERNEL32.dll_CloseHandle]
push ebx
call edi
jmp 0x3257246
mov ecx, dword [esp + 0x20]
mov dword [eax], ebp
mov eax, dword [esi]
pop ebp
pop edi
mov dword [eax + 4], ebx
mov eax, dword [esi]
mov dword [eax + 8], ecx
mov eax, dword [esi]
mov ecx, dword [esp + 0xc]
pop esi
pop ebx
mov dword [eax + 0x10], ecx
mov dword [eax + 0x14], 0
xor eax, eax
add esp, 8
ret
push 0x4b
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
call fcn.03257780
mov esi, eax
push esi
push edi
push str.file_map_create
push 0x5b
push str..._srcwin_file_map.c
push str.__s:_d__ERR___s:_cannot_map_file__S__retcode__d_n
push 0
call fcn.0325f280
mov edi, dword [sym.imp.KERNEL32.dll_CloseHandle]
add esp, 0x24
test ebp, ebp
je 0x325724d
push ebp
call edi
pop ebp
pop edi
mov eax, esi
pop esi
pop ebx
add esp, 8
ret
pop edi
pop esi
mov eax, 0x16
pop ebx
add esp, 8
ret