Function at 0x10008340
Capabilities:
Get file size
Read file on windows

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x1008bb58
mov eax, dword fs:[0]
push eax
sub esp, 0x14
push ebx
push esi
push edi
mov eax, dword [0x100ae8c8]
xor eax, ebp
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov esi, dword [ebp + 8]
xor edi, edi
test esi, esi
je 0x1000857e
mov ecx, dword [0x10152720]
xor eax, eax
test ecx, ecx
jle 0x1000838f
cmp dword [eax*4 + 0x10151a00], esi
je 0x100083fb
inc eax
cmp eax, ecx
jl 0x10008381
mov dword [0x1012d398], 0xfffff600
mov dword [0x1012d39c], 0xa00
mov dword [0x1012d3a0], 0x10
mov edi, 1
push 0x3e8
call sub.mfc100.dll_Ordinal_265
add esp, 4
mov ebx, eax
test edi, edi
jne 0x1000842f
push esi
mov esi, dword [sym.imp.MSVCR100.dll_sprintf]
push 0x1011c4d0
push str._sMap___d.JPG
push ebx
call esi
push 0x100946e0
push ebx
call dword [sym.imp.MSVCR100.dll_fopen]
add esp, 0x18
test eax, eax
jne 0x10008423
push 0x1011c4d0
push str._sMap__NoMap.JPG
push ebx
call esi
jmp 0x10008440
mov ecx, dword [eax*4 + 0x10151b40]
mov edx, dword [eax*4 + 0x10151c80]
mov eax, dword [eax*4 + 0x10151f00]
mov dword [0x1012d398], ecx
mov dword [0x1012d39c], edx
mov dword [0x1012d3a0], eax
jmp 0x100083b2
push eax
call dword [sym.imp.MSVCR100.dll_fclose]
add esp, 4
jmp 0x10008443
push 0x1011c4d0
push str._sMap__NoMap.JPG
push ebx
call dword [sym.imp.MSVCR100.dll_sprintf]
add esp, 0xc
mov eax, dword [0x1014119c]
test eax, eax
je 0x1000846d
mov ecx, dword [eax]
mov edx, dword [ecx + 8]
push eax
call edx
mov eax, dword [0x100b12f0]
mov ecx, dword [eax]
mov edx, dword [ecx + 8]
push eax
call edx
mov eax, dword [0x100b12ec]
push eax
call dword [sym.imp.KERNEL32.dll_GlobalFree]
push 0
push 0x80
push 3
push 0
push 1
push connect
push ebx
call dword [sym.imp.KERNEL32.dll_CreateFileA]
mov esi, eax
push 0
push esi
call dword [sym.imp.KERNEL32.dll_GetFileSize]
mov edi, eax
push edi
push 2
call dword [sym.imp.KERNEL32.dll_GlobalAlloc]
push eax
mov dword [0x100b12ec], eax
call dword [sym.imp.KERNEL32.dll_GlobalLock]
push 0
lea ecx, [ebp + 8]
push ecx
push edi
push eax
push esi
call dword [sym.imp.KERNEL32.dll_ReadFile]
mov edx, dword [0x100b12ec]
push edx
call dword [sym.imp.KERNEL32.dll_GlobalUnlock]
push esi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov eax, dword [0x100b12ec]
push 0x100b12f0
push 1
push eax
call dword [sym.imp.ole32.dll_CreateStreamOnHGlobal]
mov ecx, dword [0x100b12f0]
push 0x1014119c
push 0x100a3ae0
push 1
push edi
push ecx
call dword [sym.imp.OLEAUT32.dll_OleCreatePictureIndirect]
mov eax, dword [0x1014119c]
mov edx, dword [eax]
push 0x100b12ac
push eax
mov eax, dword [edx + 0x18]
call eax
mov eax, dword [0x1014119c]
mov ecx, dword [eax]
mov edx, dword [ecx + 0x1c]
push 0x100b12a8
push eax
call edx
push 0x10195948
lea ecx, [ebp - 0x20]
call sub.mfc100.dll_Ordinal_341
mov ecx, dword [0x100b12a8]
mov eax, dword [0x1014119c]
mov edx, dword [eax]
mov edx, dword [edx + 0x20]
push 0
mov esi, ecx
neg esi
push esi
mov esi, dword [0x100b12ac]
push esi
push ecx
mov ecx, dword [ebp - 0x1c]
push 0
push 0x140
push 0x140
push 5
push 5
push ecx
push eax
mov dword [ebp - 4], 0
call edx
push ebx
call sub.mfc100.dll_Ordinal_1296
add esp, 4
lea ecx, [ebp - 0x20]
mov dword [ebp - 4], 0xffffffff
call sub.mfc100.dll_Ordinal_917
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret