Function at 0x4af82d
Capabilities:
Terminate process

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x14
push ebx
xor ebx, ebx
cmp dword [ebp + 8], ebx
push esi
push edi
je 0x4afad4
mov edi, dword [ebp + 0xc]
call fcn.0041c5ff
test eax, eax
je 0x4afad4
push 1
push dword [ebp + 8]
call dword [sym.imp.GDI32.dll_SetMapMode]
push 1
push 0x42c
mov dword [ebp - 0x10], eax
xor esi, esi
call fcn.004b66ca
mov edi, eax
cmp edi, ebx
pop ecx
pop ecx
jne 0x4af88f
push 0x42c
push dword [ebp + 0xc]
push str.:4:LoadCompatibleBitmap___s___FAILED:_calloc__d__1__FAILED.
call fcn.00418e96
add esp, 0xc
jmp 0x4afa81
push 0x2010
push ebx
push ebx
push ebx
push dword [ebp + 0xc]
push ebx
call dword [sym.imp.USER32.dll_LoadImageA]
cmp eax, ebx
mov dword [ebp - 0xc], eax
jne 0x4af8c2
push str._GetLastError_
push dword [ebp + 0xc]
push str.:4:LoadCompatibleBitmap___FAILED:_LoadImage___s___FAILED:__s
call fcn.00418e96
add esp, 0xc
jmp 0x4afa7a
push ebx
push edi
push ebx
push ebx
push ebx
push eax
push dword [ebp + 8]
mov dword [edi], 0x28
call dword [sym.imp.GDI32.dll_GetDIBits]
test eax, eax
jne 0x4af8ed
push str._GetLastError_
push dword [ebp + 0xc]
push str.:8:LoadCompatibleBitmap___s___FAILED:_GetDIBits___FAILED_to_obtain_the_bitmap_properties:__s
jmp 0x4af9d9
push 0x10
push 1
call fcn.004b66ca
mov esi, eax
cmp esi, ebx
pop ecx
pop ecx
je 0x4afa71
mov eax, dword [edi + 0x14]
push dword [ebp + 8]
mov dword [ebp - 4], eax
mov ax, word [edi + 4]
mov word [esi + 0xc], ax
mov ax, word [edi + 8]
mov word [esi + 0xe], ax
call dword [sym.imp.GDI32.dll_CreateCompatibleDC]
cmp eax, ebx
mov dword [esi], eax
je 0x4af99b
movsx eax, word [esi + 0xe]
push eax
movsx eax, word [esi + 0xc]
push eax
push dword [ebp + 8]
call dword [sym.imp.GDI32.dll_CreateCompatibleBitmap]
cmp eax, ebx
mov dword [esi + 4], eax
jne 0x4af96f
movsx eax, word [esi + 0xe]
push str._GetLastError_
push eax
movsx eax, word [esi + 0xc]
push eax
push dword [ebp + 8]
push dword [ebp + 0xc]
push str.:5:LoadCompatibleBitmap___s___FAILED:_CreateCompatibleBitmap__p___d___d__FAILED:__s
call fcn.00418e96
add esp, 0x18
push dword [esi]
call dword [sym.imp.GDI32.dll_DeleteDC]
mov dword [esi], ebx
jmp 0x4af9b1
push eax
push dword [esi]
call dword [sym.imp.GDI32.dll_SelectObject]
cmp eax, ebx
mov dword [esi + 8], eax
jne 0x4af9b1
push str._GetLastError_
push dword [esi + 4]
push dword [esi]
push dword [ebp + 0xc]
push str.:3:LoadCompatibleBitmap___s___encountered_a_problem:_SelectObject__p___p__FAILED:__s
call fcn.0041936e
add esp, 0x14
jmp 0x4af9b1
push str._GetLastError_
push ebx
push dword [ebp + 0xc]
push str.:5:LoadCompatibleBitmap___s___FAILED:_CreateCompatibleDC__p__FAILED:__s
call fcn.00418e96
add esp, 0x10
cmp dword [esi + 4], ebx
je 0x4afa71
mov eax, dword [ebp - 4]
add eax, 0x64
push eax
call fcn.004b7e07
cmp eax, ebx
pop ecx
mov dword [ebp - 8], eax
jne 0x4af9e6
push dword [ebp - 4]
push dword [ebp + 0xc]
push str.:5:LoadCompatibleBitmap___s___FAILED:_malloc__d__FAILED_to_allocate_memory_for_bitmap_bits.
call fcn.00418e96
add esp, 0xc
jmp 0x4afa71
push ebx
push edi
push eax
push dword [edi + 8]
push ebx
push dword [ebp - 0xc]
push dword [ebp + 8]
call dword [sym.imp.GDI32.dll_GetDIBits]
test eax, eax
jne 0x4afa2e
movsx eax, word [esi + 0xe]
push str._GetLastError_
push eax
movsx eax, word [esi + 0xc]
push eax
movzx eax, word [edi + 0xc]
push eax
movzx eax, word [edi + 0xe]
push eax
push dword [edi + 8]
push dword [edi + 4]
push dword [ebp + 0xc]
push str.:8:LoadCompatibleBitmap___s___FAILED:_GetDIBits__d__d__d_:_d:_dx_d_FAILED_to_return_the_bitmap_bits:__s
call fcn.00418e96
add esp, 0x24
jmp 0x4afa68
mov eax, dword [edi + 8]
mov ecx, dword [edi + 4]
push 0xcc0020
push ebx
push edi
push dword [ebp - 8]
push eax
push ecx
push ebx
push ebx
push eax
push ecx
push ebx
push ebx
push dword [esi]
call dword [sym.imp.GDI32.dll_StretchDIBits]
cmp eax, 0xffffffff
jne 0x4afa68
push str._GetLastError_
push dword [ebp + 0xc]
push str.:8:LoadCompatibleBitmap___s___FAILED:_StretchDIBits___FAILED:__s
call fcn.00418e96
add esp, 0xc
push dword [ebp - 8]
call fcn.004b651e
pop ecx
push dword [ebp - 0xc]
call dword [sym.imp.GDI32.dll_DeleteObject]
push edi
call fcn.004b651e
pop ecx
push dword [ebp - 0x10]
push dword [ebp + 8]
call dword [sym.imp.GDI32.dll_SetMapMode]
cmp esi, ebx
je 0x4afad4
cmp dword [esi + 4], ebx
je 0x4afa9a
cmp dword [esi], ebx
jne 0x4afaa3
push esi
call fcn.004b651e
pop ecx
xor esi, esi
cmp esi, ebx
je 0x4afad4
mov eax, dword [0x64a5c0]
cmp eax, ebx
jne 0x4afaba
call fcn.00471551
mov dword [0x64a5c0], eax
push dword [esi]
call fcn.0047163a
mov ebx, dword [esi]
mov eax, dword [0x64a5c0]
pop ecx
push esi
call fcn.00471a4e
mov eax, dword [esi]
pop ecx
jmp 0x4afad6
xor eax, eax
pop edi
pop esi
pop ebx
leave
ret